Ich habe einen Breiten- und Längengrad von Marker in Google Maps, die ich in den Standortnamen String in Swift konvertieren möchte. Was ist der beste Weg, dies zu tun? Ich möchte die Standortadresse der Marker anzeigen und weiß nicht, wie es geht.Markieradresse (Adresse) mit einem Klick auf swift anzeigen
hier ist mein Code, der i-Marker und Breiten- und Längen hinzufügen verwendet erhalten:
func mapView(mapView: GMSMapView, didLongPressAtCoordinate coordinate: CLLocationCoordinate2D) {
if counterMarker < 2
{
counterMarker += 1
let marker = GMSMarker(position: coordinate)
marker.appearAnimation = kGMSMarkerAnimationPop
marker.map = mapView
marker.position.latitude = coordinate.latitude
marker.position.longitude = coordinate.longitude
print(marker.position.latitude)
print(marker.position.longitude)
}
}
Mögliche Duplikat: http://stackoverflow.com/questions/19025148/ios-7- add-overlay-crash-app/http://stackoverflow.com/questions/6721124/app-crashing-when-i-add-overlay-to-mkmapview/ http://stackoverflow.com/questions/31390630/exc- bad-access-using-gmaps-sdk-1-9-0-xcode-6-4-runing-auf-8-3-device/http://stackoverflow.com/questions/31264537/adding-google-maps- as-subview-crashes-ios-app-mit-exc-bad/http://stackoverflow.com/questions/24837295/how-to-solve-this-exc-bad-accesscode-exc-i38 6-gpflt-in-swift-Programmierung –