2016-08-24 11 views

答えて

0

次のコードを使用できます。選択した場所がドロップ注釈で表示されます。そして、Googleアプリからあなたをナビゲートすることができ

https://developers.google.com/maps/documentation/ios-sdk/urlscheme

if ([[UIApplication sharedApplication] canOpenURL:[NSURL 
URLWithString:@"comgooglemaps://"]]) 
{ 

NSURL *url = [NSURL URLWithString:[NSString stringWithFormat:@"comgooglemaps://?center=%f,%f&q=%f,%f",mosqueLocation.latitude,mosqueLocation.longitude, mosqueLocation.latitude,mosqueLocation.longitude]]; 
    [[UIApplication sharedApplication] openURL:url]; 
} else { 
    NSLog(@"Can't use comgooglemaps://"); 
} 
関連する問題