2010 Jul 01 7:36 AM
Hi together,
I want to modify a date field (e.g, paramter field 'pa_date like bseg-budat') by using 'Loop at screen.....modify screen'
or FM 'DYNP_VALUES_UPDATE' respectively.
Since data type 'DATS' consists of 8 digits it´s not possible to modify the field with correct format (e.g. YYYY/MM/DD, or DD/MM/YYYY using 10 digits) - that meens you can´t set the '/' or '.' .
For sure, you can use the 8-digit (internal) format (YYYYMMDD) and hit enter afterwards, but there must be some other
solution. (cf. Trx. F110)
Thanks for any help
2010 Jul 01 7:45 AM
Hi,
You cannot assign values using the LOOP AT SCREEN option. This can be used only to set the attributes of the field.
If you want to assign a value to a DATS field, you will have to assign it in YYYYMMDD format only. For example: -
pa_date = '20100701'.
Regards,
Shameek
2010 Jul 01 8:02 AM
u can modify the date field in output.....!
and show the date like 01/07/2010
let me know where u want to modify date in slection screen or in output....!
2010 Jul 01 8:14 AM
Hi,
OK, that´s what I´m doing exactly...
...
AT SELECTION-SCREEN ON VALUE-REQUEST FOR pa_laufi.
...
dynpfields-fieldname = 'PA_LAUFD'.
dynpfields-stepl = 0.
dynpfields-fieldvalue = iv_laufd. <-- iv_laufd is using the internal format YYYYMMDD
dynpfields-fieldinp = 'X'.
APPEND dynpfields.
CALL FUNCTION 'DYNP_VALUES_UPDATE'
EXPORTING
dyname = sy-cprog
dynumb = sy-dynnr
TABLES
dynpfields = dynpfields
EXCEPTIONS
invalid_abapworkarea = 01
invalid_dynprofield = 02
invalid_dynproname = 03
invalid_dynpronummer = 04
invalid_request = 05
no_fielddescription = 06
undefind_error = 07.
...
2010 Jul 01 3:35 PM
Hi Gerd,
Try
WRITE iv_laufd TO dynpfields-fieldvalue DD/MM/YYYY.
instead of
dynpfields-fieldvalue = iv_laufd.
Regards,
Ana Luisa.
2010 Jul 01 3:42 PM
Hi ,
That depends on the Date format in the User profile, for example my sap logon has the date format DD.MM.YYYY so if i run the any selection screen or Tcode with Date it will fill with the same format.
Just look at this for your profile: System -> user profile->own data.
Reagrds,
Bharani
2010 Jul 01 4:05 PM
Hi Ana Luisa,
Many thanks...it works without a hitch now.
Sorry, I don´t not how to give you 'points' - I´d give you at least 100 ;o)