I’m wondering if it’s possible to make an iphone app give the user an alert in a certain time without being run in the background or using notifications?
I see it happening in an app called iPray Pro. It gives an alert for the prayer time even though it’s not running in the background or using notifications. I checked under the Setting-Notifications and the app is not there at all.
How is it done?
Look for Local Notifications in the iOS documentation. They are like push notifications, but don’t require a server. They are quite simple API to use too; make a UILocalNotification and use the
scheduleLocalNotification:method onUIApplicationto add the notification onto the system.It will then fire in accordance to the
fireDateproperty of the local notification you scheduled.Local Notifications require iOS4.0 or later.