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

date converison

Former Member
0 Likes
774

i need to change the date conversion to mm/dd/yyyy how can i do that

5 REPLIES 5
Read only

Former Member
0 Likes
692

hi

Please try this FM.

CONVERSION_EXIT_INVDT_INPUT

CONVERSION_EXIT_INVDT_OUTPUT

1) <b>CONVERT_DATE_TO_INTERN_FORMAT</b> Converts a date to internal format

2) <b>CONVERT_FIELD_TO_EXTERN_FORMAT</b> Converts a field from internal to external format

3) <b>CONVERT_FIELD_TO_INTERN_FORMAT</b> Converts a field from external to internal format

Reward with points for helpful answers

Cheers

Alfred

Read only

Former Member
0 Likes
692

Hi

Try using,

<b>CONVERT_DATE_TO_EXTERNAL</b>

It Converts date from system storage format to users specified display format .

or

Try this,

<b>WRITE wa_olddate TO wa_newdate MM/DD/YYYY</b>.

hope this helps!

best regards,

Thangesh

Read only

Former Member
0 Likes
692

HI,

Date = YYYYMMDD

Concatenate date4(2) ‘ /’ date6(2) ‘/’ date(4) into Date2.

or

data : l_date(10) type c .

concatenate sy-datum6(2) '/' sy-datum4(2) '/' sy-datum(4) into l_date.

write : l_date.

or

data :l_date(10) type c

CALL FUNCTION 'CONVERT_DATE_TO_EXTERNAL'

EXPORTING

DATE_INTERNAL = SY-DATUM

IMPORTING

DATE_EXTERNAL = l_date.

this function module converts date from 20050601 to external format which is specified in user profile.

Regards,

Laxmi.

Read only

shishupalreddy
Active Contributor
0 Likes
692

hi,

Use the following piece of code.

DATA: L_DATE(10).

WRITE sy-datum to l_Date mm/dd/yyyy.

regards,

Read only

Former Member
0 Likes
692

hi

good

no function module can help you to change the date conversiton,

you have to store your complete date in a variable and split the three part and store in different variable.Take another variable and store only '/'.

use CONCATENAE statement to contatenate all the characters and display them using another character variable.

thanks

mrutyun^