Android Question Problem with google maps

parijs

Active Member
Licensed User
Longtime User
Hello, I use this code to open a trail in google maps.
The map looks good, but when I press the navigation button, I get the question "Use the app"
When I press, I get the error message "net :: ERR_UNKNOWN_URL_SCHEME

B4X:
Sub Globals
    Private WebView1 As WebView
End Sub
Sub Activity_Create(FirstTime As Boolean)
    Main.lat ="52.041278"
    Main.lon = "4.331661"
    Activity.LoadLayout("loadmap")
    WebView1.LoadUrl("https://www.google.com/maps/dir/?api=1&origin=current+location/&destination="& Main.lat & "," & Main.lon &"&dir_action=navigate&travelmode=walking")
End Sub
 

eurojam

Well-Known Member
Licensed User
Longtime User
In the Url you try to load you are using "current+location". you have to translate “Current+Location” into your applicable language, for example in germany I have to use: Mein+Standort

best
stefan
 
Upvote 0

MarkusR

Well-Known Member
Licensed User
Longtime User
i confirm that if you press the start navigation in the webview "browser" the error ERR_UNKNOWN_URL_SCHEME comes :(
 
Upvote 0
Top