EKRemindersMBS usage

I’m trying to understand and use the ekEventStore classes provided by MBS, specifically for accessing (adding and monitoring changes to) the Reminders app in OSX.

I can see that an ekReminder can have one or more ekRecurranceRules, and that the app generates new ekReminder events for recurrences each time the previous one is completed.

My challenge is trying to tie the resultant ekReminder events (e.g. one each week) to each other or to the originating ekRecurranceRule so that I can determine which one has been changed or added.

ekReminder has 2 ID’s - internal and external - but each ekReminder has a unique ID, and a reference back to the calendar.
ekRecurranceRules only seem to have a reference back to the calendar.

I can’t use the title or notes, as those can be modified by the user at any time.

I can’t even compare the ekRecurrance rules for each reminder, as those rules only seem to reside in the most recent ekReminder of the recurrence set.

Does anyone have any ideas as to how it might be done?

Please start to learn by reading Apple’s documentation here:


my classes basically map 1:1 and just provide a few more convenience methods.
And of course map data types.

So you like to detect when two reminder instances are based on the same base reminder with a repeating rule?

Christian - yes, that’s about right.

Reminders and my App will both generate reminders around the same repeating rules - I’d like to be able to keep then in sync so that completion in either app will show up in the other.

As far as I see the repeating reminder shows only as one reminder with one ID.
And once it’s completed, the system sets new due date and complete flag back to false.

So there should be no problem with reminders.

Yes, that is correct. The challenge then is that on completing a repeated reminder, the system then creates a new reminder for the next event and assigns the recurrence to the latest reminder.

If multiple reminders have been completed, then several reminders are created and the recurrence moves on to the latest one again.

So for all the previously completed reminders, I have no way of tracking from whence they came, as they no longer have a recurrence attached to them. Even if they did, the recurrence has no unique ID associated, so I’d have to tie them together using something else unique.

So in OSX - it is a problem - as multiple reminders can be completed and have no way of tracking.

In iOS it is a bigger problem - as Reminders there can also view Completed reminders - and change any of the associated parameters for that reminder (date, completed, notes etc).

I think I’ve found a workable solution to this by using the ekReminderMBS.url field.

Whilst this is intended for use by calendar items, it seems to be there and unused in reminder items. If it is populated when the reminder is first constructed then it seems to remain present in subsequent repeated ekReminders. By adding a URL (i’ll keep to a valid URL format) with a unique code, then you have a field that allows identifying all the elements of a reminder set.

Just have to hope that Apple doesn’t go and remove it.