mapView "userLocation" not working on Android !?

You must Login before you can answer or comment on any questions.

Hi,

I'm trying to show user's current location by using

userLocation: true
Unfortunately, it's not working on my Android device (there's no "Blue Dot" showing on the map.) But the same code is working perfectly on my iPhone device.

Here's the full code...

var win = Ti.UI.createWindow();
 
var map = Titanium.Map.createView({
    mapType : Titanium.Map.STANDARD_TYPE,
    animate : true,
    regionFit : true,
    userLocation : true
});
 
Titanium.Geolocation.getCurrentPosition(function(e) {
    var longitude = e.coords.longitude;
    var latitude = e.coords.latitude;
 
    map.setLocation({
        latitude : latitude,
        longitude : longitude,
        latitudeDelta : 0.02,
        longitudeDelta : 0.02
    });
});
 
win.add(map);
win.open();
Any idea why Blue dot is not showing on the map in Android device ?

P.S. I've tried on SDK 1.7.1, 1.7.2, 1.7.3 and 1.8.0 (all is not working)

Best regards, Neti.

— asked 2 years ago by Neti Pengkhuan
1 Comment
  • I have the same problem, did you solve it?

    Regards Matias

    — commented 1 year ago by Matias Jara

Your Answer

Think you can help? Login to answer this question!