1

I have time intervals in MutableArray like

NSMutableArray *times=[[NSMutableArray alloc]initWithObjects:@"6:00 AM", @"6:15 AM", @"6.30 AM", @"6:45 AM", nil];

Now i want to display notifications, when iphone local system time matches to that MutableArray time intervals notification has to display at every intervals. Please help me in this problem and send me the code. Thank you in advance.

Prashant Nikam
  • 2,253
  • 4
  • 17
  • 29
Ramesh Rayadurgam
  • 75
  • 1
  • 1
  • 10

3 Answers3

3

Hope this helps all who are looking out for the solution.

How To set Custom repeat interval For Nslocal Notification.....?

How to set Local Notification repeat interval to custom time interval?

iOS - how to compare two times?

Community
  • 1
  • 1
Naveen kumar
  • 800
  • 1
  • 5
  • 23
0

I guess there is no straight forward way to identify it.

You just need to write a logic on this like first get system's current time and match it with your mutable array and check for the time difference between first time array(Or array which is very close to system time)these two and put up a notification after that time difference change. Then there you go now you can identify when the array time and system time matches.

nik
  • 2,289
  • 6
  • 37
  • 60
0

You can use repeatInterval to repeat the notification. Try like this..

localNotification.repeatInterval=NSMinuteCalendarUnit;
kalyani puvvada
  • 496
  • 4
  • 12