‎2009 May 22 8:18 AM
Hi,
I need to populate a value for a field automatically when the user inputs the date of another field.
I am able to achieve this if I press ENTER, so that PBO triggers and I can populate the other field with the required value.
Suggest me a solution so that without pressing ENTER I need to achieve the scenario.
‎2009 May 22 8:38 AM
Hi,
You can achieve this by using the function module F4_DATE_CONTROL on POV module so that once you press F4 the date pop-up comes and you can get the selected date under the export parameter SELECT_DATE.
After getting the date for a particular field, use DYNP_VALUES_UPDATE to update the other field of the screen so that without pressing ENTER, i think you can achieve your requirement.
‎2009 May 22 8:25 AM
Hi,
Either press enter or place a button so that u can write code in sy-ucomm while pressing the button.
Else use the event AT SELECTION-SCREEN ON VALUE-REQUEST.
Thanks,
Mohanraj.N
Edited by: MohanrajNatesan on May 22, 2009 9:30 AM
‎2009 May 22 8:26 AM
Hi
Please find below code.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR XXXX " first field
DATA :it_dynpread TYPE TABLE OF dynpread,
wa_dynpread TYPE dynpread.
CALL FUNCTION 'DYNP_VALUES_READ'
EXPORTING
dyname = sy-repid
dynumb = sy-dynnr
request = 'A'
TABLES
dynpfields = it_dynpread.
READ TABLE it_dynpread INTO wa_dynpread WITH KEY fieldname = 'S_CAT-LOW'.
yyyyyy (2ndd field )= wa_dynpread-fieldvalue .
‎2009 May 22 8:38 AM
Hi,
You can achieve this by using the function module F4_DATE_CONTROL on POV module so that once you press F4 the date pop-up comes and you can get the selected date under the export parameter SELECT_DATE.
After getting the date for a particular field, use DYNP_VALUES_UPDATE to update the other field of the screen so that without pressing ENTER, i think you can achieve your requirement.