Как получить код страны iso3. Когда я храню сервер, но он не хранит 100% базы данных? Я использую это code.Please помочь мне Спасибо и Advance ...получить код страны iso
geocoder = new Geocoder(this);
locationManager = (LocationManager)getSystemService(LOCATION_SERVICE);
Criteria criteria = new Criteria();
bestProvider =locationManager.getBestProvider(criteria,false);
location = locationManager.getLastKnownLocation(bestProvider);
if(location!=null)
{
lat=location.getLatitude();
lng=location.getLongitude();
}
else
{
location = new Location("");
location.setLatitude((double)38.0000000000);
location.setLongitude((double)-97.0000000000);
lat =location.getLatitude();
lng=location.getLongitude();
}
Log.e("","Latitude and Longitude"+"Latitude="+lat+"Longitude="+lng);
try
{
addresses=geocoder.getFromLocation(lat,lng, 1);
}
catch (IOException e)
{
e.printStackTrace();
}
if (addresses != null && addresses.size() > 0)
{
Address address = addresses.get(0);
Log.e("Address=",""+address);
locale = address.getCountryCode();
Log.e("Locale",""+locale);
Toast.makeText(SongsList.this, "LocaleName"+locale,Toast.LENGTH_LONG).show();
}
Я уже использую этот code.Actually, у меня есть два мобильных Samsung Galaxy Ace и Htc Desire.HTC Желание работать должным образом (IND) и Samsung Galaxy Ace получите код страны Великобритания (GRB). –
Есть ли у вас ответ? –
Пожалуйста, помогите мне Спасибо Advance .. –