I see iOS applications like Facebook that send notifications even if the application hasn’t been launched.
I need to schedule a task with a timer that gets executed at every time interval, and this task (should be inside the same application) should deliver a NSUserNotification if meets some conditions.
How can you set up such a notification even if the application isn’t running?
Facebook app and other apps that send notifications when they were not launched do this by using the remote notification mechanism.
To use this, you need to setup a server, create push certificates and use a APNS library for your preferred server.
Take a look here for details: http://www.raywenderlich.com/3443/apple-push-notification-services-tutorial-part-12