Microsoft
Software
Hardware
Network
Question : java get utc date/time
I need to get the UTC/GMT current date/time. I'm using the below and it adds "-0700" at then end...is this code valid?
private String getCurrentDate(){
Calendar cal = new GregorianCalendar();
cal.setTimeZone(TimeZone.g
etTimeZone
("GMT"));
DateFormat formatter = new SimpleDateFormat("yyyy-MM-
dd'T'HH:mm
:ssZ");
return formatter.format(cal.getTi
me());
}
result of above is 2010-05-19T16:39:15-0700
Answer : java get utc date/time
take the Z out of the date format string
Random Solutions
Add Imap/Pop3 email to blackberry
Excel 2007: Sorting Data In Columns
Create task in task scheduler programmatically
sql server query
Can I perform a clean install with a recovery disc?
Extend timout in web.config for session variables
Lables printing problem using MS Word
Exchange config for Outlook Anywhere
outlook 2007 keeps faulting in module msoert2.dll
equation for multi level slope for LUT table in range from 0 to 255