Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Problem with the date conversion

Former Member
0 Likes
762

Hi Friends,

i am facing the problem with the date conversion, Actuall my requirement is to pass the date to the screen based on the user setting roles(SU01).

I have fetched the user setting date format by using the funciton module SUSR_GET_USER_DEFAULTS, The function module picks the exact user date setting (Like as MM/DD/YYYY, MM.DD.YYYY, DD.MM.YY).

After that i have implemented the FORMAT_DATE_4_OUTPUT funciton module for converting of the user role setting date format into system date format.

for the english language case the funciton module FORMAT_DATE_4_OUTPUT works fine but the funciton module not supported for other languages

Can you please provide the Function Moudle for user setting date conversion.

The funciton module is most important for us,

Thanks

Charan

Moderator message: date conversion questions = FAQ, please search before posting.

Edited by: Thomas Zloch on Dec 21, 2010 2:19 PM

4 REPLIES 4
Read only

anup_deshmukh4
Active Contributor
0 Likes
681

have you tried using WRITE TO SY-DATUM TO <CHAR10>.

Write will take care of the thing ..!

Hope this helps

Read only

Former Member
0 Likes
681

Hi,

Try using the statement 'WRITE date USING EDIT MASK mask'.

Thanks,

Sudheer

Read only

Former Member
0 Likes
681
Read only

Former Member
0 Likes
681

Hope this logic helps you.

DATA LF_DATE    TYPE DATS VALUE '21122010'. " 21-dec-2010
DATA LF_DATE_BI(10).

WRITE LF_DATE TO LF_DATE_BI.  "Now LF_DATE_BI contains the date in user format

"Now populate the value LF_DATE_BI to the screen field