NSDateFormatter vs. -setTimeZone: ?
NSDateFormatter vs. -setTimeZone: ?
- Subject: NSDateFormatter vs. -setTimeZone: ?
- From: Jim Correia <email@hidden>
- Date: Wed, 18 Jan 2006 22:51:05 -0500
Is it expected that -setTimeZone: is ignored for NSDateFormatters not
using the 10.4 behavior?
If I create a date formatter and do
[dateFormatter setTimeZone: [NSTimeZone timeZoneForSecondsFromGMT: 0]];
[dateFormatter setFormatterBehavior: NSDateFormatterBehavior10_4];
[dateFormatter setDateFormat: @"yyyy-MM-dd"];
It keeps the local time zone. Reversing the first two lines makes the
change to GMT stick.
(If this isn't the expected behavior, I'm happy to write a bug. In
any case, it caught me by surprise.)
Jim
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden