NSTimer to fire while device is locked

Posted by edie on Stack Overflow See other posts from Stack Overflow or by edie
Published on 2011-01-07T09:03:51Z Indexed on 2011/01/07 10:53 UTC
Read the original article Hit count: 327

Filed under:
|
|
|
|

Hi,

I'm currently creating an alarm. I use NSTimer to schedule my alarms. My problem is when the device was put into locked mode my NSTimer doesn't fire. I think that the NSTimer will not fire because my app goes to suspended state when it is lock. Can you help me find a solution to my problem?

I've found some topics about UIBackgroundModes, but I don't know how it will help me.

Thanks..

The problem in UILocalNotification is when the device was in silent, the sound will not be hear. My implementation was I'm using NSTimer to fire an alarm when the app is in foreground or device is locked but app currently running. When the applicationDidEnterBackground: is called I schedule the UILocalNotification as the alarm.

© Stack Overflow or respective owner

Related posts about iphone

Related posts about nstimer