cancel
Showing results for 
Search instead for 
Did you mean: 

Different Date format in Sap script for VF03

0 Kudos

Hi,

We are using VF03 to print the document. For one Payer the Date format is coming as MM.DD.YYYY which is perfect but for another user it is coming as wierd value. When we check in the code one place there was a Write statement for this.

For one payer the write statement is converting as DD.MM.YYYY and for other payer it is YYYY/MM/DD.

what was the actual problem and what could be the solution.

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

This message was moderated.

former_member156446
Active Contributor
0 Kudos

make sure you are using SET COIUNTRY key word in your print program... search in SCN for more info on set country.

Former Member
0 Kudos

Hi,

Check on what basis the Date conversion is done. If the format you need is MM.DD.YYYY then you can comment the Write Statement to avoid unnecessary conversions.

Regards,

Vaishali.

Former Member
0 Kudos

Hi,

Dint get you clearly, are you telling that the date format is coming in different format for differente user with the same example? or if it is the same user but with different example?

if the example doc is same but geting different date format for different user, then check the user default date format setings in tcode su3 for both the user and compare.

normaly the write statement will convert the date into the user default seting format, if it is the other case then it has to be checked.

0 Kudos

Same user. When i am executing VF03 for document number 100 the date format is coming as DD.MM.YYYY for another document 200 it is coming as YYYY/MM/DD.

Former Member
0 Kudos

Hi,

Please check the user settings in the path --- SYSTEM ---> USER Profile ---> Own data -


> Defaults Tab ---> Date format

If it is like DD.MM.YYYY u will get the same other wise there are diff types of date formats..

Regards,

Srinivas.

Former Member
0 Kudos

Hi

Check whether your Sript is using this command ..

/: SET COUNTRY country_key

your program is checking for KUNNR & his address and country key for the Given KUNNR and based on the country key the DATE format is printing..

Chk

http://help.sap.com/abapdocu_70/en/ABENCOUNTRY_FORMATS.htm

and chk Transaction Code: OY01

surya

Former Member
0 Kudos

Hi

Your program is check for the KUNNR and his COuntry Key and based on this it is printing the Date on COUNTRY KEY based. Check in SCRIPT for

/: SET COUNTRY country_key

CHeck this link

http://help.sap.com/abapdocu_70/en/ABENCOUNTRY_FORMATS.htm

Transaction Code: OY01

Surya