Calling Google Maps with Multiple Addresses from an iOS App

I did not manage to start the Google maps application with several destinations, and I did not find anything, indicating whether this is possible or not.

while this code is great for a single destination and the current location of users:

UIApplication *app = [UIApplication sharedApplication]; [app openURL:[NSURL URLWithString: @"http://maps.google.com/maps?saddr=Curent+Location&daddr=San+Francisco,+CA"]] 

`

Now with two destinations and the current location of users, like this, it does not work:

  UIApplication *app = [UIApplication sharedApplication]; [app openURL:[NSURL URLWithString: @"http://maps.google.com/maps?saddr=Curent+Location&daddr=San+Francisco,+CA+to:los+angeles,+CA"]] 

`The result is a route to the last destination.

I am currently looking for a solution for iOS and Android os, as the application works on both. Basically there will be a list of saved places that the user can choose to create a trip, to deliver them to one destination, where they can stop and do something, and then continue navigation to the next place.

+6
source share

Source: https://habr.com/ru/post/892106/


All Articles