On 12/12/2010, at 21:01, Kyle Sluder wrote:

> On Sun, Dec 12, 2010 at 2:58 PM, Siegfried
> <triebschen.siegfried.id...@gmail.com> wrote:
>> On 12/12/2010, at 20:41, WT wrote:
>> 
>>> Hello,
>>> 
>>> according to the iOS 4.2 NSDateFormatter class documentation, the -init 
>>> method is available in iOS 2.0 through iOS 3.2,
>> 
>> Sorry, but the init method? Just to confirm, where exactly in the 
>> documentation did you read about this?
> 
> http://developer.apple.com/library/ios/#documentation/Cocoa/Reference/Foundation/Classes/NSDateFormatter_Class/DeprecationAppendix/AppendixADeprecatedAPI.html%23//apple_ref/doc/uid/20000447-BAJBJEGB
> 
> --Kyle Sluder

Ouch! :-)

NSDateFormatter *dateFormatter = [[NSDateFormatter alloc] init];
        
[dateFormatter setLocale:[NSLocale systemLocale]];
[dateFormatter setDateStyle:NSDateFormatterShortStyle];
        
NSLog(@"%@", [dateFormatter stringFromDate:[NSDate date]]);

Looks like works here


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please 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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to