![]() |
| photo from: financialeconomyblog |
October 22, 2015 - 35th Day As An iOS Developer With No Experience
So I was back to the project that I hate. Well, I do not hate it so much, it is just quite complex for me to handle for now. And this project was initially made by a group of interns in our company. You see, it was my first time to continue a project that was made by the others. lol. As I am writing this post, I heard, yeah again, my grand mother worrying about money. Gahhh! She stays here in the house yet she is stuck in debt. She always cries.
Anyway, I had an OT today. I would like to share this to you:
HOW TO ADD A LOCAL NOTIFICATION TO YOUR APP?
- I bet this is the right way to add local notification to your app, and you can just add timer in your codes to automatically notify your user locally. :)
UILocalNotification *localNotification = [[UILocalNotification alloc] init];
localNotification.fireDate = [NSDate dateWithTimeIntervalSinceNow:0.1];
localNotification.alertBody = @"POKE";
localNotification.applicationIconBadgeNumber = [[UIApplication sharedApplication] applicationIconBadgeNumber] + 1;
[[UIApplication sharedApplication] scheduleLocalNotification:localNotification];




Post a Comment