Android Question GoogleMap - Show Marker Title and button

Pravin Shah

Member
Licensed User
Longtime User
Hello,

I have added some location using AddMarker in GoogleMap. Now I want that location is shown with it's snippet (marker title) displayed. By default the marker is shown without snippet when map is loaded. When you click on it, it shows the snippet.
So what is the method or code to display the snippet by default (please refer to screenshot attached)


Also my requirement is to add a button on map. On click of this button, the app should show distance and direction in googlemap. The googlemap has this in-built functionality when you select a marker and click on direction icon, it shows the direction and distance from your current location.
So what method or code should be used to achieve this functionality.
 

Attachments

  • Map.jpeg
    Map.jpeg
    65.4 KB · Views: 473

DonManfred

Expert
Licensed User
Longtime User
By default the marker is shown without snippet when map is loaded. When you click on it, it shows the snippet.
B4X:
    Dim mark As Marker = gmap.AddMarker(50.83374976,6.44135244, "Hello!!!")
    mark.InfoWindowShown = True
 
Upvote 0
Top