I have find way to send intnet to google maps for navigation between "Current location" and some destination.
Is it possible to send intent that will start navigation between two locations?
Thank you for replay.
That is what I have, but i need to send Deatination and Location.
I want it to show path from location that I will specify to the destination, not from currnet location.
Dim i As Intent
i.Initialize(i.ACTION_VIEW, "http://maps.google.com/maps?saddr=New York City, NY,&daddr=Washington, DC")
i.SetComponent("com.google.android.apps.maps/com.google.android.maps.MapsActivity")
StartActivity(I)
This is the code that I use now for Intent for google maps from Current location to some other location.
When intent starts it goes to maps and open window to start geting directions and field destination is populated with lat, lon and field Start point says My location. I would like for that field also to be populated with location ( example 40,720, -74,005).
B4X:
Dim lat As Double: Dim lon As Double
Dim Intent1 As Intent: Dim URI As String
lat=latitude
lon= longitude
URI= "geo:" & lat & "," & lon & "?q=" & lat & "," & lon
Intent1.Initialize(Intent1.ACTION_VIEW,URI)
Intent1.SetComponent("googlemaps")
StartActivity(Intent1)
Can you help me write URI for your example. The example above doesnt open maps directly but ask me with which program to open.
I hope I am making sense