‎2007 Sep 20 5:31 AM
Hi All,
I dont get any values returned when I use the FM below,
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
RETFIELD = LW_RETFIELD ->field for the f4 help dislpay
PVALKEY = ' '
DYNPPROG = SY-REPID
DYNPNR = SY-DYNNR
DYNPROFIELD = ' '
STEPL = 0
WINDOW_TITLE =
VALUE = ' '
VALUE_ORG = 'S'
MULTIPLE_CHOICE = ' '
DISPLAY = ' '
CALLBACK_PROGRAM = ' '
CALLBACK_FORM = ' '
MARK_TAB =
IMPORTING
USER_RESET =
TABLES
VALUE_TAB = LTB_VALUES ->table with values for F4 help display
FIELD_TAB =
RETURN_TAB = LTB_RETURN
DYNPFLD_MAPPING =
EXCEPTIONS
PARAMETER_ERROR = 1
NO_VALUES_FOUND = 2
OTHERS = 3
I am not getting any exception. But when I click on the F4 help, there are no values displayed. The F4 help is blank. I dont know if I have to pass anything more.
The field that I need to display in the F4 help is not a dictionary field.
Please let me know if anyone know why this is happening.
Thanks,
Sruthy
‎2007 Sep 20 5:43 AM
hi sruthi,
concept is: get the data from database table into int table and pass this table to value_table in the function module.
see below sample code...
SELECT werks prctr matgp FROM zprctr INTO TABLE i_matgp.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'S_MATGP_LOW'
pvalkey = 'S_MATGP-LOW'
dynpprog = p_v_syrepid "sy-repid
dynpnr = sy-dynnr
dynprofield = 'S_MATGP-LOW'
value_org = 'S'
callback_program = p_v_syrepid "sy-repid
TABLES
value_tab = i_matgp
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
and please do the changes accordingly then ur problme will solve.
thanks,
maheedhar
‎2007 Sep 20 5:43 AM
hi sruthi,
concept is: get the data from database table into int table and pass this table to value_table in the function module.
see below sample code...
SELECT werks prctr matgp FROM zprctr INTO TABLE i_matgp.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'S_MATGP_LOW'
pvalkey = 'S_MATGP-LOW'
dynpprog = p_v_syrepid "sy-repid
dynpnr = sy-dynnr
dynprofield = 'S_MATGP-LOW'
value_org = 'S'
callback_program = p_v_syrepid "sy-repid
TABLES
value_tab = i_matgp
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
and please do the changes accordingly then ur problme will solve.
thanks,
maheedhar
‎2007 Sep 20 6:23 AM
Hi Maheedhar,
I did the changes as u had said but the F4 help still shows no output.
I am not selecting from the database.
I have defined the field locally as i am passing a couple of fixed values to the F4 help.
TYPES: BEGIN OF TY_VALUES,
XXXX(20) TYPE C,
END OF TY_VALUES.
For the field XXX, I need an F4 help.
Thansk,
Sruthy
‎2007 Sep 20 6:42 AM
Hi,
Check the below code.
SELECTION-SCREEN: BEGIN OF BLOCK main WITH FRAME.
PARAMETERS: p_date(10) TYPE c.
SELECTION-SCREEN: END OF BLOCK main.
For Run date
DATA: BEGIN OF it_laufd OCCURS 0,
laufd LIKE reguh-laufd, "Run date
END OF it_laufd.
*----
Validation Section
*----
INITIALIZATION.
SELECT DISTINCT laufd FROM reguh INTO TABLE it_laufd.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_date.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'LAUFD'
dynpprog = sy-repid
dynpnr = sy-dynnr
dynprofield = 'P_DATE'
value_org = 'S'
TABLES
value_tab = it_laufd
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
‎2007 Sep 20 7:00 AM
‎2007 Sep 20 7:27 AM
Hi Rajesh,
Thank you so much...Its working now!!
The heading is displayed as "Char20". Can you tell me how to change that?
Thanks,
Sruthy
‎2007 Sep 20 7:35 AM
Hi,
<i>The heading is displayed as "Char20". Can you tell me how to change that?</i>
To change header use the link i provided earlier
Regards,
Samson Rodrigues.
‎2007 Sep 20 7:42 AM
If you want to change the description then either populate the <b>TABLES</b> parameter <b>FIELD_TAB</b> or change the declaration of the internal table so that it refers to a dictionary field which has a description of ur choice.
‎2007 Sep 20 5:45 AM
hi
good
go through this link
http://help.sap.com/saphelp_45b/helpdata/en/9f/dbaac935c111d1829f0000e829fbfe/content.htm
thanks
mrutyun^
‎2007 Sep 20 6:16 AM
‎2007 Sep 20 7:15 AM
Hi Samson,
I have defined a local internal table which has the field I need to have displayed in the F4 help.
I passed the values to the table as shown below,
MOVE 'ABCD' TO LT_VALUES-VALUE.
APPEND LWA_ID_VALUES TO LT_VALUES.
MOVE 'EFGH' TO LT_VALUES-VALUE.
APPEND LWA_ID_VALUES TO LT_VALUES.
I then passed this table, LT_values to the 'VALUE_TAB' in the function module.
Do I have to use the ''Field Tab" option? if yes, since it is of type, DFIES, can you tell me which fields have to be populated as there are so many fields in DFIES.
Thanks,
Sruthy
‎2007 Sep 20 6:46 AM
hi,
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
regards,
‎2007 Sep 20 7:18 AM
Hi all,
I am using this Func module under the veent, POV. It is a module pool program.
Thanks,
Sruthy
‎2007 Sep 20 6:48 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 20 6:54 AM
Hi Sruthi,
if not mistaken try to declare ur Internal table with Data statement.
in the below code u have declared with Types statement.
If ur Declare with Type only the structure is created no memory is created so no values will be stored in the Internal Table.
use
data:begin of itab,
field(300),
end of itab.
instead of
types:begin of itab,
field(300),
end of itab.
‎2007 Sep 20 7:20 AM
Hi,
I have defined an internal table using DATA:.
I just defined the structure using TYPES.
Thanks,
Sruthy
‎2007 Sep 20 7:30 AM
Hi Sruthy,
Follw this Procedure.
If you are writing the Report program do the following in the Event "at selection-screen on value Request" or if you are writing the Code for Module pool program do the following in the Event "Process on value request".
1.Select the data from the database table that you want to display in the F4 Help.
2. Pass this internal table in the function module 'F4IF_INT_TABLE_VALUE_REQUEST'
Reward if it is helpful.
Regards,
Ashok.