0

I want to get notified when my application is in background with :

[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(calendarChanged:) name:EKEventStoreChangedNotification object:nil];

I tried to implement it but (calendarChanged:) never get called ?!

akashivskyy
  • 44,342
  • 16
  • 106
  • 116
Alaa12
  • 47
  • 2
  • 8

1 Answers1

2
  1. You should specify the EKEventStore object when registering the notification observer

  2. Your method is not going to be called while in background, it will be called once your app comes to foreground.

Taken from this question, the search option doesn't hurt.

Community
  • 1
  • 1
akashivskyy
  • 44,342
  • 16
  • 106
  • 116