‎2008 Jan 01 9:10 AM
Hi all,
i want to reverse the date ex - 20080101 is the system date
reverse - 01012008.
i want only the function module.
‎2008 Jan 01 9:14 AM
‎2008 Jan 01 9:17 AM
‎2008 Jan 01 9:25 AM
hi
ther are many options. but uthis case if u change the user master record.or select the date format in table usr01.
the hard coating is not at all god and it also have limitation .
this function module also helps u.
CONVERT_DATE_TO_EXTERNAL Converts date from system storage format to users specified display format
let me know if u are not able to get it.
reward all help full answers
/: SET DATE MASK = 'date_mask'
In the date mask, you can use the following codes:
DD: day (two digits)
DDD: day name - abbreviated
DDDD: day name - written out in full
MM: month (two digits)
MMM: month name - abbreviated
MMMM: month name - written out in full
YY: year (two digits)
YYYY: year (four digits)
LD: day (formatted as for the L option)
LM: month (formatted as for the L option)
LY: year (formatted as for the L option)
Assuming the current system date is March 1st, 1997.
/: SET DATE MASK = 'Foster City, MM/DD/YY'
&DATE& -> Foster City, 03/01/97
/: SET DATE MASK = 'MMMM DD, YYYY'
&DATE& -> March 01, 1997
The date mask may be reset to the default setting by using an empty string:
/: SET DATE MASK = ' '
In most print programs there is a function module called as below.
By setting the export parameter PI_COUNTRY one can set the form to print all dates according to country without any further coding.
CALL FUNCTION 'WFMC_PREPARE_SMART_FORM'
EXPORTING
PI_NAST = NAST
PI_COUNTRY = IS_DLV-LAND
PI_ADDR_KEY = IS_ADDR_KEY
PI_REPID = LF_REPID
PI_SCREEN = XSCREEN
IMPORTING
PE_RETURNCODE = CF_RETCODE
PE_ITCPO = LS_ITCPO
PE_DEVICE = LF_DEVICE
PE_RECIPIENT = CS_RECIPIENT
PE_SENDER = CS_SENDER.
regards,
pavan
‎2008 Jan 01 9:31 AM
Hi Vijay,
U can use following logic also....
move yyyy into one variable,mm in one variable and dd in one variable and concatenate as ddmmyyyy
‎2008 Jan 01 12:36 PM
if u r printing the system date in the report ..it gets reversed and printed.
‎2008 Jan 01 2:24 PM
Hi,
simply use the WRITE in the follow way:
-
DATA: lv_input_date TYPE d,
lv_reverse TYPE c LENGTH 8.
lv_input_date = '20080101'.
WRITE lv_input_date TO lv_reverse.
WRITE lv_reverse.
-
lv_reserve contains: 01012008
-
Kindly regards,
Stefan