Accessing AppDelegate instance

AppDelegate object can access from any class in the same application like below. Methods or properties shared between controllers can be defined under application delegates.

SomeAppDelegate *appDelegate
  = (SomeAppDelegate *)[[UIApplication sharedApplication] delegate];

No comments yet.

Leave a Reply