Hi,

I have a property in a bean like this:

Code:
<property name="dateOfBirth"><value>1994-04-22 00&#58;00</value></property>
The date I get instantiated in my bean looks like this:

date = Fri Apr 22 00:00:00 GMT-01:00 1994

ie, it is being created in my own locale (BST).

I made my own CustomDateEditor, which is just like the one supplied with Spring, but it has a constructor like this:

Code:
public CustomDateEditor&#40;&#41;&#123;
		dateFormat = new SimpleDateFormat&#40;"yyyy-MM-dd HH&#58;mm"&#41;;
		dateFormat.setTimeZone&#40;TimeZone.getTimeZone&#40;"GMT"&#41;&#41;;
		allowEmpty = false;
	&#125;
Using this, the date in my bean looks like this:

date = Thu Apr 21 23:00:00 GMT-01:00 1994

ie, an hour has been subtracted from the time, but the time zone remains the same.

I need dates in UTC, or GMT. I want my date to look like:

date = Fri Apr 22 00:00:00 GMT 1994

Can anyone help?

Thanks,

John