cancel
Showing results for 
Search instead for 
Did you mean: 

formatting date in a table in webdynpro

Former Member
0 Kudos

Hi

We are obtaining data from database in a table . the table has a date column which is displaying date in mm/dd/yyyy format .we want it in dd/mm/yyyy format .is there any property of column that we can use for setting this format or is there any other way?

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Add a calculated attribute under the table's data source node and convert the date in the generated get-method. Bind the table cell editor to this attribute.

Armin

Former Member
0 Kudos

Hi anzar,

DateFormat format = new SimpleDateFormat("dd//mm//yyyy");

java.sql.Date t;

t = your backend value(mm/dd/yyyy);

finalvalue=format.format(new java.util.Date(t.getDate);

get in dd/mm/yyyy format.

thanks,

dibyendu.

Former Member
0 Kudos

Hi ,

just change ur dekstops propeties date format ill change do the following settings , date format is not problem with webdynpro or table properties they are browser settings/

goto Control Panel ->Regional and Language Options change the languaue settings to English UK.

Thanks

Sunitha Hari

Former Member
0 Kudos

Hey,

Retreiving the date column from output node.

thru itterate method.

Set the chaged fromat to that Column.

follow this way:

int soze = wdcontext.node<uro/pnode()>().size();

for(int i=0;i< size();i++)

{

IPrivateViewName.INodeElement ele = (IPrivateViewName.INodeElement)wdcontext.currentNodeelement().getElementAt(i);

ele.setDate(format(ele));

}

It will helps u.

Thanks,

Lohi.

Edited by: Lohitha M on Feb 28, 2008 12:29 PM