The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
January 2001



This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.


Offset with GMT

Posted by Guria on June 06, 2001 at 1:26 PM

I want to know the offset of the current time with GMT. I have a variable field called ZONE_OFFSET in the Calendar class(java.util.calendar) which gives me the offset with GMT in milliseconds. Now I want to convert this offset in milliseconds into the format hh:mm(hours:minutes).
Please tell me how to do it. I have done it but using a very complex logic. Is there any java function that can do this in no time. Kindly help me.
Awaiting your reply,


Sponsored Links

Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us