tags:

views:

26

answers:

0

Hi there I have a Sqlite DB with a query that is placed in the Appdelegate to return an array of objects.

From other views I can instantiate the appDelegate and retrieve objects that are set there but I cannot pass a value to one of its methods such as below.

If anyone has any advice as to how to do that I'd be grateful.Also is it better practice to set the database query in the appdelegate or within the class of the objects that I want to retrieve?

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

[appDelegate queryLocation:(location)];

thanks