views:

426

answers:

1

Hi,

In my iphone application i have used MK MapView to navigate from different pages. But when the MKMapView controll run at that time the the control is not going back again in the application.so i am loosing the application flow,and i have to run the application again.

/* [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://maps.google.com/maps?q=category:Taxi=NSW=australia"]];*/

The above code giving me search string as query in the application.And able to put pin points in the Map.But the control not remains in the application.

How to set the controll in application again and navigate after loading Map?

Pls give any code snippet or useful link,which would be appreciated.

Thanks,

Mishal Shah

A: 

I am not really sure of what you're asking but I'll try my best:

If you use the openURL: method of UIApplication your application will quit, this is expected behavior.

You probably need to create a UIViewController that implements the MKMapViewDelegate protocol.

Unfortunately the MapKit documentation supplied by Apple is severely lacking - but I think it sounds like you don't really have a great understanding of how view controllers work. You should check out Apple's View Controller Programming Guide

bpapa