I'm trying to get all the events from a determined EKCalendar
, but if I call eventsMatching Predicate:
with a predicate generated with predicateForEventsWithStartDate:endDate:calendars:
and a past 'startDate
' I get a null object. It's a bug? Or there is no way I can retrive the past events?
EDIT (NSData decalarations):
[[self eventStore] predicateForEventsWithStartDate:[NSDate distantPast] endDate:[NSDate distantFuture] calendars:syncedCalendars]
Try change your code to to:
Also make sure that your syncedCalendars is NSArray type.