cancel
Showing results for 
Search instead for 
Did you mean: 

Problem printing date on the form

Former Member
0 Kudos

Hello friends ,

I am doing form for the HR . Is there any special formatting needed to print the date on the form . I am doing this .

&t_payment-paydate& in the main window of the form .

t_payment is the table and paydate the date of payment . But instead of printing 1/22/2006 . It is printing 3//20/07/2 some junk value . Is it the format related problem ?

Any suggestions . You help would be greatly appreciated .

Regards & Thanks ,

Hari

Accepted Solutions (1)

Accepted Solutions (1)

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos

Make sure paydate is type like sy-datum, or a DATS type field.

Regards

Rich Heilman

Answers (1)

Answers (1)

venkata_ramisetti
Active Contributor
0 Kudos

HI,

You can do like this.

You make the following changes in the program

1. Define a character type field

data: v_payment_date(10) type c.

2. Assign the date value to the character field

write t_payment-paydate to v_payment_date.

You make the following changes in your sapscript text element.

instead of using field t_payment-paydate use v_payment_date.

Thanks

Ramakrishna