i used these ways,
updated infoplist like additional file
also used these codes
CLLocationManager locationManager;
public override void ViewDidLoad()
{
base.ViewDidLoad();
// Perform any additional setup after loading the view, typically from a nib.
locationManager = new CLLocationManager();
locationManager.DesiredAccuracy = CLLocation.AccuracyBest;
locationManager.ActivityType = CLActivityType.Other;
if (locationManager.RespondsToSelector(new MonoTouch.ObjCRuntime.Selector("requestWhenInUseAuthorization")))
{
locationManager.RequestWhenInUseAuthorization();
}
myMap.ShowsUserLocation = true;
myMap.DidUpdateUserLocation += (sender, e) =>
{
if (myMap.UserLocation != null)
{
CLLocationCoordinate2D location;
location.Latitude = myMap.UserLocation.Coordinate.Latitude;
location.Longitude = myMap.UserLocation.Coordinate.Longitude;
myMap.CenterCoordinate = location;
myMap.ShowsUserLocation = true;
}
};
myMap.ShowsUserLocation = true;
locationManager = new CLLocationManager();
locationManager.AuthorizationChanged += OnAuthorizationChanged;
locationManager.LocationsUpdated += OnLocationsUpdated;
locationManager.DesiredAccuracy = CLLocation.AccuracyBest;
locationManager.ActivityType = CLActivityType.Other;
myMap.ShowsUserLocation = true;
myMap.DidUpdateUserLocation += (sender, e) =>
{
if (myMap.UserLocation != null)
{
CLLocationCoordinate2D location;
location.Latitude = myMap.UserLocation.Coordinate.Latitude;
location.Longitude = myMap.UserLocation.Coordinate.Longitude;
myMap.CenterCoordinate = location;
myMap.ShowsUserLocation = true;
}
};
but i cant show location,
problem may on ide or sdk?