How to disable Day Light Saving Change with GMT-5 TimeZone ?

Hi,

I want to use a Calendar object for date manipulation, but I want

to disabled DST, because it adds and removes 1 hour depending

on the calculation.

I took a look at severals books but without success. I found a solution at

http://mindprod.com/jgloss/gotchas.html#DATE , but it uses UTC TimeZone

which is innapropriate in my case. I must use date with the GMT-5 TimeZone

I want to know if there's a way to disable DST for the GMT-5 TimeZone ?

Thanks in advance ?

[535 byte] By [eric_hudon] at [2007-9-30 10:35:50]
# 1
Have you tried GregorianCalendar and TimeZone classes?
Peter-Lawrey at 2007-7-3 19:31:35 > top of Java-index,Administration Tools,Sun Connection...
# 2

yes .. here's a snipset a my code...

formatDateUTC.setTimeZone(TimeZone.getTimeZone("UTC"));

Calendar cal = Calendar.getInstance();

cal.setTimeZone(TimeZone.getTimeZone("UTC"));

eric_hudon at 2007-7-3 19:31:35 > top of Java-index,Administration Tools,Sun Connection...
# 3

> I want to know if there's a way to disable DST for the GMT-5 TimeZone ?

Yes, but have you tried

TimeZone.getTimeZone("GMT-5")?

In theory, that should give you a DST-invariant time zone 5 hours behind GMT.

When I just tried at (at 10:45AM PDT here), I got a time of 12:45 with this timezone (by using a SimpleDateFormat with this timezone to format a new Date()), which shows that it is ignoring DST.

shankar.unni at 2007-7-3 19:31:35 > top of Java-index,Administration Tools,Sun Connection...