Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UILocalNotification vs UNNotificationRequest #4

Open
mohan-shyam opened this issue Sep 28, 2016 · 2 comments
Open

UILocalNotification vs UNNotificationRequest #4

mohan-shyam opened this issue Sep 28, 2016 · 2 comments

Comments

@mohan-shyam
Copy link

mohan-shyam commented Sep 28, 2016

Now while we use the new notifications framework, repeats option is Boolean.

var trigger = UNTimeIntervalNotificationTrigger.withTimeInterval(5.0, repeats: false)

But earlier, in UILocalNotification, we could specify different repeatIntervals.

localNotification.repeatInterval = .Minute

localNotification.repeatInterval = .Month

Is there a way to do that in the new framework?

@hokim-m
Copy link

hokim-m commented Nov 18, 2016

@mohan-shyam Perhaps, your problem could be solved with UNCalendarNotificationTrigger. See https://developer.apple.com/reference/usernotifications/uncalendarnotificationtrigger

@mohan-shyam
Copy link
Author

@hokim-m , thank you. I seem to have arrived at a solution, although there are many situations which can't be implemented with the new framework.

Please find the solution at, http://stackoverflow.com/questions/37804287/how-do-i-set-an-nscalendarunitminute-repeatinterval-on-ios-10-usernotifications/39784684#39784684

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants