Hey hey,
I'm getting problems with getFromLocationName. Every time I run it, it
stalls at the line:
List<Address> addresses = geocoder.getFromLocationName("Megazone
Leicester, Leicester, LE1 3HS, UK", 1);
with a LogCat Error of:
java.io.IOException: Service Not Available
at android.location.Geocoder.getFromLocationName(Geocoder.java.
159).
I've had a look around and it seems to be a bug, but can anyone verify
it, as some people seem to have it working fine.
Geocoder geocoder = new Geocoder(this);
List<Address> addresses =
geocoder.getFromLocationName("Megazone Leicester, Leicester, LE1 3HS,
UK", 1);
Address SiteAddress = addresses.get(0);
Double geoLat = SiteAddress.getLatitude() * 1E6;
Double geoLng = SiteAddress.getLongitude() * 1E6;
GeoPoint point = new GeoPoint(geoLat.intValue(), geoLng.intValue());
Ta muchly :-)
--
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en