I try a long time , but it is not work.
who is the people can help me,
my code
line code
1 Locale locale = new Local(edittext.getText().toString
());
2 Geocoder geoCoder = new Geocoder(this , locale);
line 2 ,use "this" the compiler can`t do. what`s wrong?
if I change this to getBaseContext(), the compiler is working.
but no result.
3 try{
4 List<Address> addresses = geoCoder.getFromLocationName
("empire state
5 building",5);
6 String add = "";
7 if(addresses.size() > 0){
8 p = new GeoPoint(
9 (int)(addresses.get(0).getLatitude() * 1E6),
10 (int)(addresses.get(0).getLongitude()* 1E6));
11 overlayItem = new OverlayItem(point , "","");
12 itemizedOverlay.addOverlay(overlayItem);
13 mapView.getController().animateTo(point);
14 }else
15 }catch(IOException e){
16 e.printStackTrace();
17 }
the document describe use Geocoder class most has backend service .
what is it and howto use .
--
You received this message because you are subscribed to the Google Groups
"Android Discuss" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/android-discuss?hl=en.