Application Development 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: 

Pass value from return field from F4 value request functionality

Former Member
0 Kudos

Hi,

I have this table control and have 2 columns, in which in the first column I have implemented a F4 process on value request. In the module I'm also populating the second column depending on the value of the first column. The problem is only the first column is getting populated with the selected data from the f4 list. During debug both columns have data. Any hints why this is happening?


PROCESS ON VALUE-REQUEST.
  FIELD gt_copa-sfienm MODULE f4_sfienm.

  CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
    EXPORTING
      retfield        = 'SFIENM'
      value_org       = 'S'
    TABLES
      value_tab       = lt_list
      return_tab      = lt_return
    EXCEPTIONS
      parameter_error = 1
      no_values_found = 2
      OTHERS          = 3.
  IF lt_return[] IS NOT INITIAL.
    READ TABLE lt_return INTO ls_return INDEX 1.
    READ TABLE lt_list INTO ls_list WITH KEY name = ls_return-fieldval.
    IF sy-subrc EQ 0.
      gt_copa-sfienm = ls_list-characteristic. " First column of table control 
      gt_copa-txt_m  = ls_list-name.             " Second column of table control
    ENDIF.
  ENDIF.

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi,

U should call the F4 Help FM for every field or column.

Try calling it 2 times passing different reffield...

Hope its clear!!

Regards,

Pavan

2 REPLIES 2

Former Member
0 Kudos

Hi,

U should call the F4 Help FM for every field or column.

Try calling it 2 times passing different reffield...

Hope its clear!!

Regards,

Pavan

Former Member
0 Kudos

Hi,

Try this.

From the lt_return table get the value of SFIENM. Then use the value and fetch the next column details from the lt_list and use the function module 'DYNP_VALUES_UPDATE' and fill both the columns in the table control.

Hope this helps you.

Regards,

Sharin.