cancel
Showing results for 
Search instead for 
Did you mean: 

Defalut value in Date fields

Former Member
0 Kudos

I have a Date as input field in my View, I want to default the today Date for this fields.

Also, I want to show the date in the fields.

BR,

Ali

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Ali,

System variable sy-datum gives you the current date from the system. while displaying the DATE in wd4a you must be using textview or input field which must be binded to DATE type attribute in the context.

Use set_attribute method to set this ATTRIBUTES value to SY-DATUM.

Greetings

Prashant

Edited by: Prashant on Feb 28, 2009 8:54 PM

Answers (2)

Answers (2)

Former Member
0 Kudos

Thnks all.

My issue solved

former_member402443
Contributor
0 Kudos

Hi Ali,

For setting the default value in date field, you have to do the following things

1. Declare a attribute of type D in your view.

2. Bind the attribute to the input field of your view.

System variable sy-datum gives you the current date from the system

3. So Set the attributes value using

set_attribute by passing the sy-datum value in the value property.

Regard

Manoj Kumar