cancel
Showing results for 
Search instead for 
Did you mean: 

How to implement Date Picker

Former Member
0 Kudos

Hi experts,

I am very new to WebDynpro.In my application i need to use Date Picker, can anyone of you suggest me how to proceed.

Regards,

Prasanna.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Create an attribute of type date and bind it to a input field

Ex: Context

DateAttr - >of type date.

create a inputfield bind its value to this attribute

Regards

Ayyapparaj

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Prasanna

1) Create a Value Attribute of Type "<b>Date</b>' [Say MyDate]

2) Create an InputFieldUIElement

3) Now Bind that "MyDate" to the <b>Value </b>property of InputFieldUIElement

Regards

Chaitanya.A

Former Member
0 Kudos

Hi Chaitanya,

Thank you very much for your reply.Your answer really solved the problem but the date is in mm/dd/yyyy format, Is there any possibility of changing the format to dd/mm/yyyy.

Regards,

Prasanna.

Former Member
0 Kudos

Hi Prasanna,

2. Create a simple type under (<project>>Dictionary>Local Dictionary>Data Type>Simple Type--> Right Click and select Create Simple Type

Specify the name of your simple type say Date1 and package

2. Uder representation tab--> set the format of your date as dd/mm/yyyy.

3. Create a context attribute called Date1 and set its type to the simple type that you created (selecting the browse ... button ).

4. Bind this context to the input field.

Regards,

Murtuza

Former Member
0 Kudos

HI Prasanna

You can try this also as you are creating a date picker without using SimpleType and Representation.so you can achieve this by coding

Date d = wdContext.<your node>Element().get<your value attribute>();

SimpleDateFormat sdf = new SimpleDateFormat("dd.MM.yyyy");
Date reqDate= sdf.format(d);

Hi Even if you chage the format sometimes you will not get the desired output at that time

Try these options

1) Change your Internet Explorer [The Browser which you are using] language

2) In Application Level, ie in Webdynpro

a)Go to <Your project name>>Webdynpro>Applications--><Your Application>

Double click on your Application name

b) Go to Application Properties TAB, Add a New Application Property

c) Click on "Browse" and Select DefaultLocale and mention the Value as

en_US [If you didnt mention any thing here by default it will take browser's language]

3)In your Portal check the language setting of particular user in identity management

Warm Regards

Chaitanya.A