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

F4IF_INT_TABLE_VALUE_REQUEST

Former Member
0 Likes
631

Hi Experts,

Any suggestions on how to deal with this kind of requirement?

Value of matnr: AAAA-00-01

Using FM F4IF_INT_TABLE_VALUE_REQUEST, i want to populate in my selection-screen only the first 4 character of MATNR, (AAAA) to be use in my selection-screen using select-option as shown below:

ITEM: From - AAAA To -DDDD

Will anybody share some code for me to be able to this?

Is the FM F4IF_INT_TABLE_VALUE_REQUEST suitable for this?

Thanks,

Yu

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
556

Hi,

before sendin the data to the FM 'F4IF_INT_TABLE_VALUE_REQUEST ' convert it into the format you want and send that table to the FM... This will solve your problem..

First pass the data to the fm :

C147_STRING_SPLIT_AT_POSITION.. It will split your data at the required postion..

then pass this internal table to the FM...


LOOP AT itab INTO wa_itab.

  CALL FUNCTION 'C147_STRING_SPLIT_AT_POSITION'
       EXPORTING
            i_string   = wa_itab
            i_position = 4
       IMPORTING
            e_head     = wa_itab2.

  APPEND wa_itab2 TO itab2.

ENDLOOP.

CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
     EXPORTING
          retfield     = 'WA_ITAB2-field1'
          dynpprog     = sy_repid
          dynpnr       = sy-dynnr
          window_title = text-002
          value_org    = 'S'
     TABLES
          value_tab    = ITAB2
          return_tab   = gt_matnr_returned.

4 REPLIES 4
Read only

Former Member
0 Likes
557

Hi,

before sendin the data to the FM 'F4IF_INT_TABLE_VALUE_REQUEST ' convert it into the format you want and send that table to the FM... This will solve your problem..

First pass the data to the fm :

C147_STRING_SPLIT_AT_POSITION.. It will split your data at the required postion..

then pass this internal table to the FM...


LOOP AT itab INTO wa_itab.

  CALL FUNCTION 'C147_STRING_SPLIT_AT_POSITION'
       EXPORTING
            i_string   = wa_itab
            i_position = 4
       IMPORTING
            e_head     = wa_itab2.

  APPEND wa_itab2 TO itab2.

ENDLOOP.

CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
     EXPORTING
          retfield     = 'WA_ITAB2-field1'
          dynpprog     = sy_repid
          dynpnr       = sy-dynnr
          window_title = text-002
          value_org    = 'S'
     TABLES
          value_tab    = ITAB2
          return_tab   = gt_matnr_returned.

Read only

0 Likes
556

Trying to analyze...

Read only

0 Likes
556

Thanks for your replies. Problem solved!

Read only

Former Member
0 Likes
556

call this FM in AT slection-screen output event.

Populate the internal table from matnr(4) from whatever table u r referring for select options.

And pass this internsl table to ur FM.