Application Development 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: 

How to find user's current date format ?

Former Member
0 Kudos

Hi guys,

i need to display some variable as per the user's current date format.

But it is always following DD.MM.YYYY whereas my user format is MM/DD/YYYY.

i know how to see it in system -- > user profile --> own data....

But i need to write code to find the current date format ...

HELP ME

1 ACCEPTED SOLUTION

Former Member
0 Kudos

How can i write date in DD.MM.YYYY to a variable ???

11 REPLIES 11

former_member533584
Contributor
0 Kudos

hi,

date format is stored in USR01 table.

regards,

ananth

Former Member
0 Kudos

Hi,

Try this:

data: l_date_string(10).

write l_date to l_date_string.

write l_date_string.

Former Member
0 Kudos

Hi!

It is stored in USR01 table DATFM field (its a number, which means a specific format).

Regards

Tamá

Former Member
0 Kudos

you can write a select on USR01 table

select DATFM from USR01 into V_DATFM where bname eq sy-uname.

0 Kudos

Any Function module to change the date to user's current date format ????

0 Kudos

try with this

CONVERT_DATE_TO_EXTERNAL

Former Member
0 Kudos

How can i write date in DD.MM.YYYY to a variable ???

0 Kudos

data: v_date(10).

write sy-datum to v_date using edit mask '__.__.____'.

0 Kudos

What is edit mask? is it the option of write statement ?//

0 Kudos

No one suggested to use edit mask ...it is not present in write statement help also

Thanks alot Ravi...

0 Kudos

Hi GUru,

It is there in write statement help. Under formatting options i guess.

Regards,

Ravi