I want to show a particular geo location on google maps. I can't use mapview / mapactivity.
Also I can't use action view intent
Can I use webview for this?
Open a url like this should work:
webView.loadUrl("http://maps.google.com/maps?q=47.404376,8.601478");
Replace 47.404376,8.601478 with your lat / long. Works in the browser, I guess on a mobile device it will open a mobile version of Google Maps.
Check out google Static Map API https://developers.google.com/maps/documentation/staticmaps/?hl=nl
You have to construct an url that displays a static image of a map (possible markers) of your location. you can then download it and display it in an imageview.
String latitude= "45.838211";
String longitude = "9.334661";
String url = "http://maps.google.com/maps/api/staticmap?center=" + latitude + "," + longitude+ "&zoom=10&size=400x400&sensor=false"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With