I am developing a location based iphone application which searches the near by stores based on the distance. I used the standard unit of distance in Kilometer. But i want to change the unit of distance according to the standard unit of each Countries. Can i able to change the unit of distance from the iphone settings ? The distance format should be location based default: in South Africa: KM, in the States: MI.
I want to get it in the following units also – o Feet o Miles o Nautical Miles o Meters o Kilometers o Ri (Korea) o Ri (Japan) o ETC!!! –
I am developing a location based iphone application which searches the near by stores
Share
You can get the locale that the phone is set to this way:
and ask it about units of measure this way:
This will answer “Metric” or “U.S.”. There’s a lot more you can check in the NSLocale class ref.