Geocoder class is not working properly in android
My application I'm using Geocoder class for retrieve the location latitude and longtude
My code is :
addr开发者_StackOverflowessInput = street+","+city+","+pin+","+country;
List<Address> foundAdresses = gc.getFromLocationName(addressInput, 5);
First time it is throwing exception like this
java.io.IOException:Unable to parse response from server
ERROR/ProtoRequestListener(566): com.google.common.async.WatchdogException
Plese resolve it and if you have any code retrieve the location latitude and longitude send me
This should solve your problem.
List<Address> addresses =
new Geocoder(this,Locale.getDefault()).getFromLocation(lat, lon, 1);
精彩评论