Geocoder doesn't work on some of the Android phones
问题 I am working on Android application which allows user to enter the address and converts to latitude and longitude for further use. I am using following code to get lat and long addresses = geocoder.getFromLocationName("11381 zapata ave san diego", 1); if (addresses.size() > 0) { double latitude = addresses.get(0).getLatitude(); double longitude = addresses.get(0).getLongitude(); addGeoFence(latitude, longitude); tlFragmentMap.setLatLong(new LatLng(latitude, longitude)); return true; } else {