views:

640

answers:

1

I'm using addTimeInterval for creating local notification but it seems that it is now deprecated (iOS 4).

My code:

localNotif.fireDate = [now addTimeInterval:timeInterval];

Xcode's warning:

'addTimeInterval:' is deprecated (declared at /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.0.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSDate.h:27)

What should I use instead? Thanks.

+7  A: 

-dateByAddingTimeInterval:.

KennyTM
Thank you very much.
ibeitia