How to convert date to MM/dd/yyyy format in table.

Hi.
I want to convert date to MM/dd/yyyy format in table without converting it to string as I am using that table dates for some date validations.

Hi

you can use the SimpleDateFormatter

final DateFormat fmt = new SimpleDateFormat("MM/dd/yyyy");
fmt.format(date)

Greets

Edit: Oh sorry. I read about that you doesn’t want to convert to String. So you could use JodaTime. With JodaTime you can handle almost all date issues.

Override formatPropertyValue(Object rowId, Object colId, Property property) . This will only affect the View, while the data in the container keeps to be a Date-Object.

Thank!!!
It worked…