File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
REST with Spring (video course)
this week in the
Java in General
Problem with converting TimeZone as PST
Joined: Oct 12, 2007
Jul 01, 2009 11:19:01
I have problem with converting
here the problem is i can able to convert timezone, it is showing time properly, but while trying to get in milli secs iam getting different timezone
like EDT , GMT ...
here is my code
Date startTime = new Date(); TimeZone.setDefault ( TimeZone.getTimeZone ("PST")) ; Calendar c=Calendar.getInstance(); System.out.println("Date : "+c.getTime()); System.out.println("Time in mill's "+c.getTimeInMillis());
can you please let me know your thoughts,
Joined: Jun 09, 2009
Jul 05, 2009 10:07:53
Err....you may want to read the API docs.....
I agree. Here's the link:
subject: Problem with converting TimeZone as PST
Need to specify the time as GMT while creating the date, JVM is on EST
Time Zone problem
Problem in Changing Timezone (URGENT)
Problem in setting TimeZone to PST
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015