‎2007 Sep 19 4:30 AM
Hi,
I have an internal table with field ORDERNO. How do I use in this FM to get data?
I am not able to get any F4 help though I have given all values.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'ORDERNO'
dynpprog = 'ZTEST'
dynpnr = '1010'
dynprofield = 'S_ord-LOW'
TABLES
value_tab = orders
EXCEPTIONS
parameter_error = 1
NO_VALUES_FOUND = 2
others = 3.
any help?
regards,
ashish
P.S.: Points will be rewarded
‎2007 Sep 19 4:35 AM
Hi Ashish,
Where you call this FM.
You should call this FM under PROCESS ON VALUE-REQUEST
Check this Sample Code,
PROCESS ON VALUE-REQUEST.
FIELD D0200_FIELD_TAB-BUFFER MODULE D0200_VALUE_REQU.
MODULE d0200_value_requ.
"call the FM here.
CALL FUNCTION 'F4IF_FIELD_VALUE_REQUEST'
EXPORTING
tabname = tabname
fieldname = fname
SEARCHHELP = ' '
SHLPPARAM = ' '
dynpprog = progname
dynpnr = dynnr
dynprofield = ' '
stepl = dynp_stepl
value = value_bef_f4
MULTIPLE_CHOICE = ' '
DISPLAY = ' '
SUPPRESS_RECORDLIST = ' '
callback_program = progname
callback_form = 'CALLBACK_F4'
TABLES
return_tab = return_tab
EXCEPTIONS
field_not_found = 1
no_help_for_field = 2
inconsistent_help = 3
no_values_found = 4
OTHERS = 5.
....
........
..........
ENDMODULE. "d0200_value_requ
Thanks,
Reward If Helpful.
‎2007 Sep 19 4:35 AM
Hi Ashish,
Where you call this FM.
You should call this FM under PROCESS ON VALUE-REQUEST
Check this Sample Code,
PROCESS ON VALUE-REQUEST.
FIELD D0200_FIELD_TAB-BUFFER MODULE D0200_VALUE_REQU.
MODULE d0200_value_requ.
"call the FM here.
CALL FUNCTION 'F4IF_FIELD_VALUE_REQUEST'
EXPORTING
tabname = tabname
fieldname = fname
SEARCHHELP = ' '
SHLPPARAM = ' '
dynpprog = progname
dynpnr = dynnr
dynprofield = ' '
stepl = dynp_stepl
value = value_bef_f4
MULTIPLE_CHOICE = ' '
DISPLAY = ' '
SUPPRESS_RECORDLIST = ' '
callback_program = progname
callback_form = 'CALLBACK_F4'
TABLES
return_tab = return_tab
EXCEPTIONS
field_not_found = 1
no_help_for_field = 2
inconsistent_help = 3
no_values_found = 4
OTHERS = 5.
....
........
..........
ENDMODULE. "d0200_value_requ
Thanks,
Reward If Helpful.
‎2007 Sep 19 4:36 AM
hi,
tables: t001.
data: begin of it001 occurs 0,
bukrs type t001-bukrs,
end of it001.
fetch data into internal table as u require using select.
select-options s_bukrs for t001-bukrs.
at selection-screen on value-request for s_bukrs-low.
call function 'F4IF_INT_TABLE_VALUE_REQUEST'
exporting
retfield = 'BUKRS'
dynprofield = 'S_BUKRS'
dynpprog = sy-cprog
dynpnr = sy-dynnr
value_org = 'S'
tables
value_tab = it001.
regards
siva
‎2007 Sep 19 4:38 AM
Hi Ashish,
Here is the eg:
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'CODE'
dynpprog = sy-repid
dynpnr = sy-dynnr
dynprofield = 'S_PRESS'
window_title = 'F4'
value_org = 'S'
TABLES
value_tab = i_values
field_tab = i_fields
return_tab = i_return.
READ TABLE i_return INTO wa_return WITH KEY fieldname = 'CODE'.
You have to pass the return table parameter in the tables section in which you will be getting the selected value and also the field table parameter mentioning the fields.
Regards,
Ravi G
‎2007 Sep 19 5:10 AM
Hi,
call this FM under....
AT SELECTION-SCREEN ON VALUE-REQUEST FOR s_orderno-low.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'ORDERNO'
dynpprog = 'ZTEST'
dynpnr = '1010'
dynprofield = 'S_ord-LOW'
TABLES
value_tab = orders
EXCEPTIONS
parameter_error = 1
NO_VALUES_FOUND = 2
others = 3.
Regards,
‎2007 Sep 19 5:12 AM
Hi Ashish,
Please call this function module in Process On Value Request.
please see below steps.
1) get the data of order number into internal table or into variable.
2) call the function module
3) pass this value to value_tab = <int table name> or <variable name>.
then ur code should work.
thanks,
maheedhar