0

Reviewing question: How to set the repeat UILocal Notifications on the select list of Weekdays

On the complexity of creating repeating alarms, would it be acceptable to simply have an alarm schedule everyday in the background (easy), but then contain logic to only alert the user during the days they originally set to repeat on?

For example: They set an alarm to repeat only on Weds, Fri, Sunday at 10am. So the alarm is set to repeat everyday at 10, in the background, but there is logic to filter out the days that were not chosen to repeat. Thus the user will only see the alert on Weds, Fri, Sunday, but it will be going off everyday "in the background".

Is this permitted?

Community
  • 1
  • 1
Sauron
  • 6,399
  • 14
  • 71
  • 136
  • In your example, you would need three separate notifications – Paulw11 May 05 '16 at 20:56
  • The question was created to get away from needling to create and manage those separate notifications. Just have one everyday that is then fileted given their selection. Is this allowed? – Sauron May 05 '16 at 21:02
  • I understand that, but the answer is you can't. Notifications can only have simple repeat periods - daily, weekly and once you have scheduled a notification delivery is managed by iOS, not your app, so you don't have any opportunity to 'filter' delivery. – Paulw11 May 05 '16 at 21:04
  • Is there a class like alarm manager (in android) in iOS where I could schedule something like this? – Sauron May 05 '16 at 21:10
  • You can add events to the iOS calendar using EventKit. Events can have complex notification schedules. – Paulw11 May 05 '16 at 21:11
  • @Paulw11, When using Event Kit, is there a way to prevent my apps' events from populating within the users calendar/reminder apps? – Sauron May 05 '16 at 22:39
  • No, that is what event kit does, it populates the users calendar – Paulw11 May 05 '16 at 22:41
  • @Paulw11, ok, changing strategies, what about a central server handling events? is that too much? not dependable? (can we enter a chat?) – Sauron May 06 '16 at 00:11
  • Let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/111169/discussion-between-paulw11-and-sauron). – Paulw11 May 06 '16 at 00:11
  • I think what I'm going to end up doing is a hybrid approach. So the server will basically send out to the app using a secure Channel to schedule the local notifications for the day. And that occurs once every day at 4 a.m. EST – Sauron May 06 '16 at 02:44

0 Answers0