Also, if you mean "Eastern Standard Time" and "Eastern Daylight Time" then they are the same time zone and no conversion is necessary. It doesn't make sense to ask for a time to be formatted as if it were daylight saving time, if it isn't.
Joined: Jan 18, 2006
I had tried like what you had described but it is displaying GMT as its time zone when we set the TimeZone in the code "df.setTimeZone(TimeZone.getTimeZone("EDT"));" My requirement is to display the time zone as EDT always without any loss of time.
Joined: Jan 07, 2006
getTimeZone returns UTC when the parameter you pass to it is not the name of a time zone. What exactly is "EDT"? Does it have daylight savings time?
You could check out the SimpleTimeZone class; with it you can create a TimeZone object with any offset and daylight savings time rules you want.