Questions tagged [eventkit]

EventKit is a framework on iOS and OS X which provides classes for accessing and modifying calendar event information.

From the documentation:

The Event Kit and Event Kit UI frameworks together allow applications to access event information from a user’s Calendar database. You can fetch events based on a date range or a unique identifier, receive notifications when event records change, and allow users to create and edit events for any of their calendars. Changes made to events in a user’s Calendar database with Event Kit are automatically synced with the appropriate calendar (CalDAV, Exchange, and so on)

The EventKit framework provides classes for accessing and manipulating calendar events and reminders.

Event Kit not only allows your app to retrieve users’ existing calendar and reminder data, but it also lets your app create new events and reminders for any of their calendars. In addition, Event Kit lets users edit and delete their events and reminders (collectively known as “calendar items”). More advanced tasks, such as adding alarms or specifying recurring events, can be achieved with Event Kit as well. If a change to the Calendar database occurs from outside of your app, Event Kit is able to detect the change by notification so your app can act appropriately. Changes made to calendar items with Event Kit are automatically synced to the associated calendar (CalDAV, Exchange, and so on).

Event Kit provides limited access to a user’s Calendar database; it does not include everything that would be desired for implementing a full-featured calendar or reminder app, such as adding attendees or accounts.

Reference:

1.EventKit Constants Reference

2.EventKit Framework Reference

3.Introduction to Calendars and Reminders

4.EventKit UI Framework Reference

Sample Code:

SimpleEKDemo

567 questions
184
votes
11 answers

Programmatically add custom event in the iPhone Calendar

Is there any way to add iCal event to the iPhone Calendar from the custom App?
Vadim
  • 9,383
  • 7
  • 36
  • 58
51
votes
7 answers

Find first element matching condition in Swift array (e.g. EKSource)

I would like to find the first EKSource of type EKSourceType.Local with a "single"-line expression in Swift. Here is what I currently have: let eventSourceForLocal = eventStore.sources[eventStore.sources.map({ $0.sourceType }) …
Drux
  • 11,992
  • 13
  • 66
  • 116
28
votes
2 answers

EKParticipant in EventKit erroneously returns NO for isCurrentUser property

I'm attempting to determine which of an EKEvent's attendees (EKPartipants) is the current user. In iOS6, EKParticipant exposes a property called…
Rahul Jaswa
  • 509
  • 4
  • 17
27
votes
4 answers

iPhone simulator - how to detect when app is running on simulator (so can setup test data)?

Any sample code that would show me how to, in my iPhone application code: How to detect if the application has just been DEPLOYED to be run to a simulator (and not a device) [if "Deployed" isn't available, then just detecting when the app is being…
Greg
  • 34,042
  • 79
  • 253
  • 454
25
votes
1 answer

Google Delegates on Calendar Framework / EventKit

I have always run with the assumption that Google delegates can be viewed by iCal and the calendar.app, but are not visible to us developers through the calendar framework, or EventKit. Has this changed?
the Reverend
  • 12,305
  • 10
  • 66
  • 121
24
votes
2 answers

Modifying EKParticipants (attendees) in EventKit like Sunrise

My goal is to add some invitees to an EKEvent. I've looked into other questions like this, such as this one, but all say that it is essentially impossible to add EKParticipants to an EKEvent programmatically. I do see that the attendees property is…
rebello95
  • 8,486
  • 5
  • 44
  • 65
20
votes
3 answers

What exactly constitutes a "full calendar sync" in EKCalendar?

The documentation for the EKCalendar class states this for the calendarIdentifier property: A full sync with the calendar will lose this identifier. You should have a plan for dealing with a calendar whose identifier is no longer fetch-able…
user1869469
  • 491
  • 4
  • 13
18
votes
1 answer

Adding EKParticipants to an EKEvent in EventKit

I'd like to programatically add a participant to an EKEvent on the iPhone. EKParticipant's class reference states "You do not create EKParticipant objects directly. Send attendees to an EKEvent object to get an array of EKParticipant…
Glenn Barnett
  • 2,031
  • 1
  • 21
  • 31
17
votes
5 answers

App Calendar Functionality No Longer working in ios 6

In the app I am currently developing there is interaction between the user and the users calendar, like what happens in many apps, very standard stuff. It was working fine until I upgrade to ios 6. I am now faced with the "This app does not have…
JLoewy
  • 535
  • 1
  • 4
  • 17
14
votes
5 answers

Customizing calendar events/alerts in iOS EventKit?

I'm writing my first iOS app (I'm tired of missing event reminders and want to have a rule based reminder that, for example for certain calendars and certain people, will ring a different, louder tone, 10, 5 and 0 minutes before the event) The…
Eran Medan
  • 44,555
  • 61
  • 184
  • 276
14
votes
4 answers

How to open calendar with event - NSURL calshow:

I'm wondering if there is someone who knows how to launch calendar with a specific event from APP I've done some research and I've come up with two ways to open native calendar from inside the app using NSURL "calshow://" which opens calendar at…
Fero
  • 567
  • 8
  • 25
14
votes
2 answers

Add Event to calendar in xcode iOS

Hy I have this code for adding Events to calendar but it does not add. -(void)event { EKEventStore *eventStore = [[EKEventStore alloc] init]; EKEvent *event = [EKEvent eventWithEventStore:eventStore]; event.title = @"Event"; …
WildWorld
  • 517
  • 1
  • 5
  • 18
12
votes
3 answers

Fetch all events from EventStore EventKit iOS

i would like to know how to fetch all events from an EventStore using EventKit in iOS. This way i can specify all events for today: - (NSArray *)fetchEventsForToday { NSDate *startDate = [NSDate date]; // endDate is 1 day = 60*60*24…
Nicolas S
  • 5,325
  • 3
  • 29
  • 36
12
votes
2 answers

Difference between EKEvent's eventIdentifier and calendarItemExternalIdentifier

Reading Apple's docs, I'm still confused as to what the difference is between EKCalenderItem's calendarItemExternalIdentifier and EKEvent's eventIdentifier, and which one we should use to identify calendar events across different devices.…
Z S
  • 7,039
  • 12
  • 53
  • 105
12
votes
0 answers

iOS EventKit EKCalendar unique (global) identifier

Is there a property that can be used to recognize calendars across devices? According to the Apple docs, the "calendarIdentifier" property cannot be used: A full sync with the calendar will lose this identifier. You should have a plan for dealing…
ebi
  • 4,862
  • 6
  • 29
  • 40
1
2 3
37 38