-[NSDateFormatter dateFromString:] and non-standard formats
-[NSDateFormatter dateFromString:] and non-standard formats
- Subject: -[NSDateFormatter dateFromString:] and non-standard formats
- From: Nick Zitzmann <email@hidden>
- Date: Tue, 30 Jan 2007 21:02:01 -0700
I checked the archives and didn't see anything relevant...
I'm using a 10.4-style NSDateFormatter with a non-standard date
format ("YYYYMMdd'T'HHmmss"). I'm trying to pass the string
"20061029T130000" into the date formatter and get an NSCalendarDate
in return. I did send -setGeneratesCalendarDates: with YES to the
formatter. I'd expect to get a calendar date set to October 29, 2006
at 1 PM in the date formatter's time zone, but what I actually get in
return is nil.
Has anyone ever tried using -[NSDateFormatter dateFromString:] with a
non-standard date format before and gotten it to work? I'm really
hoping I don't have to write my own parser...
Nick Zitzmann
<http://www.chronosnet.com/>
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden