How to show alerts from the application when it is not running?
I have an application in which I have to show the alerts for user specied reminders, I am able to show these reminders when my application is running but my problem is i have to show thsese reminders to the user when my application is not running? is it possible to show the alerts or remindsers when the application is running?
what i obsered in iphone native applications(messages, emails) it whill show no of unread or new messages at the top right tip of the icon on the desktop and it will keep on updates these co开发者_StackOverflow中文版unt. Can I impplement these king of alerts to my applications? if yes how? it not is there any other to show the alerts when application is not running?
Have a look at Push Notifications. Otherwise this it is not possible.
You'll note that the applications that do this were all written by Apple. As of V3.x of the iPhone, no third party applications can run in the background.
The official way to support this kind of functionality is to use Push Notifications. This requires a server-side component. Push notifications allow you to update the "unread count" or display messages exactly as you describe.
- Above both answers are right.
- Actually, you can never ever display alerts when application is terminated.
- Remember that "iPhone" doesn't allow any background processing.
- The alerts that you see are push notifications - which are sent from apple server to iphone.
- Basically you need to study about push notifications.
- Push notifications are sent from server to iPhone only when it is registered.
- ( application registers for push notifications - which you can see in settings ).
精彩评论