3

In Android one can use an URI to call GoogleMaps as follows

https://www.google.com/maps/search/?api=1&query=47.5951518,-122.3316393&query_place_id=ChIJKxjxuaNqkFQR3CK6O1HNNqY

As given in this answer.

This query opens the GoogleMaps on Android devices and the place info is shown as in the below screenshot:

enter image description here

I'm looking for a similar result for IOS with GoogleMaps. I have searched in GoogleMaps SDK documentation and also over the internet but couldn't find an answer.

Can we achieve this for IOS with GoogleMaps?

Yunus Karakaya
  • 531
  • 3
  • 16

1 Answers1

5

Yes you can open Google Maps from your iOS App. There is a documentation available for opening Google Maps Via iOS App.

An example would be:

UIApplication.shared.openURL(URL(string:"https://www.google.com/maps/search/?api=1&query=47.5951518,-122.3316393&query_place_id=ChIJKxjxuaNqkFQR3CK6O1HNNqY")!)

For this to work, there should be Google Maps App installed on the device. Though if you have the Placeid and Google SDK installed on your APP then you must have it's Latitude and Longitude. You can open default Maps to do this task for you. This SO Post is a great place to start!

Sahil Manchanda
  • 9,812
  • 4
  • 39
  • 89