Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
In this example, we are creating an event that occurs on the same day, every month, for an entire year. The steps are as follows:
Create an instance of EKEventStore.
Find a modifiable calendar inside the calendars array of the event store (for
more information, refer to Recipe 14.1).
Create an object of type EKEvent (for more information, refer to
Recipe 14.2).
Set the appropriate values for the event, such as its
startDate and endDate (for more information, refer to
Recipe 14.2).
Instantiate an object of type NSDate that contains the exact date when
the recurrence of this event ends. In this example, this date is
one year from today’s date.