Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

module pool table control problem

Former Member
0 Likes
771

Hi everybody,

          I've created a screen in which there is a table control...

  there are two columns i  that table control.

suppose if i've selected a value for first column than respective value for second column must appear in search help and on selection that value must not appear in the next search help for 2nd row 2nd column.

thank you

6 REPLIES 6
Read only

Former Member
0 Likes
637

HI

USE CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'.

The internal table ll be filled with search help values,

Use READ statement to delete the first row second column value from internl table and pass the updated internal table to the above function module.

check the demo pgm "DEMO_DYNPRO_F4_HELP_MODULE "  and DEMO_DYNPRO_TABCONT_LOOP


If you want to set the custom F4 help for a field, write the module inside the statement PROCESS on VALUE REQUEST. Then use the function module f4if_int_table_value_request to populate the custom search help.

Example:

  PROCESS ON VALUE-REQUEST.
  FIELD <field name> MODULE <module name>

MODULE  <module name> INPUT.

http://wiki.scn.sap.com/wiki/display/ABAP/Filtering+F4+Help+values+in+Table+control,+based+on+other+...

Thanks

Vijay

Read only

Former Member
0 Likes
637

DATA :

        lv_stepl                TYPE          sy-stepl ,

        t_screen_values  TYPE TABLE OF dynpread ,

        x_screen_values  TYPE          dynpread,

     

       t_rtn                        TYPE TABLE OF       ddshretval.

"----------------------------------------------------------------------------------------------

"to fetch the stepl of the screen

CALL FUNCTION 'DYNP_GET_STEPL'  



    IMPORTING

      povstepl = lv_stepl.

"----------------------------------------------------------------------------------------------

"adding fields for which value on screen to be fetched


  x_screen_values-stepl     = lv_stepl .

  x_screen_values-fieldname = 'ZAPS_SERVICE-SER_NAME' ."fieldname

  APPEND x_screen_values TO t_screen_values .


"reading the screen value for corresponding screen

  CALL FUNCTION 'DYNP_VALUES_READ'

    EXPORTING

      dyname     = sy-repid

      dynumb     = sy-dynnr

    TABLES

      dynpfields = t_screen_values.



  READ TABLE t_screen_values INTO x_screen_values INDEX 1 .

  IF sy-subrc = 0.

    SELECT     item_name         "fetching item name based on the hotel and type of service

               price

    FROM       zapt_item_list

    INTO TABLE lt_item_name

    WHERE      hid EQ zapt_bokin_head-hid AND service_name = x_screen_values-fieldvalue .



    IF sy-subrc = 0 .

      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'

        EXPORTING

          retfield    = 'ITEM_NAME'

          dynpprog    = sy-repid

          dynpnr      = sy-dynnr

          dynprofield = 'ZAPS_SERVICE-ITEM_NAME'

          value_org   = 'S'

        TABLES

          value_tab   = lt_item_name

          return_tab  = t_rtn.

      CLEAR lt_item_name .

    ENDIF.

I think this will help you

Read only

Former Member
0 Likes
637

Hi Sujeet Takalkar,

Use dyanamic search help. This can be achieved with the help of Fm 'F4IF_INT_TABLE_VALUE_REQUEST'.

Please refer the thread for more details of dynamic search help,

https://scn.sap.com/thread/928071

Thanks,

Riju.

Read only

RaymondGiuseppi
Active Contributor
0 Likes
637

Try to manage it in the POV :

(Many threads already at scn, use search tool)

Regards,

Raymond

Read only

Former Member
0 Likes
637

Hi Sujeet,

Check my solution to a similar requirement in this thread.

http://scn.sap.com/thread/3427692

Read only

Former Member
0 Likes
637

Hi Sujeet,

Try your code in POV.