iOS local push

Source: Internet
Author: User

The local notification service for iOS requires the use of nslocalnotification to process notifications based on time behavior. For example, the time to inform the user to learn.
There are three things to consider when using nslocalnotification:
Scheduled time: A period that specifies the date and time when the iOS system sends notifications;
Notification type: Notification type (including warning message, action button caption, application icon on badge (digital marker) and playback sound);
Custom data, local notifications can contain a dictionary type of local data.
Limits on the number of local notifications, iOS allows up to 64 recent local notifications, and local notifications exceeding the limit will be ignored by iOS.
Examples of Use:
Uilocalnotification *notification=[[uilocalnotification alloc] init];
NSDate *now=[nsdate New];
Notification.firedate=[now addtimeinterval:100];
Notification.timezone=[nstimezone Defaulttimezone];
[Email protected] "remind you to learn iOS";
[[UIApplication sharedapplication] schedulelocalnotification:notification];

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.