Question : GPS Longitude and Latitude to City Names

How to map a given GPS Longitude and Latitude to the corresponding city name (e.g. 25 17.565N 55 22.803E which is located in "Dubai" city)? The GPS coordinates are stored in a  MS SQL database.

Thanks and Regards

Answer : GPS Longitude and Latitude to City Names

you can create a field like 25N22E (using lat and lon degrees) next to each city, then you can search for all cities with that value, this will give you a list of "candidates", then calculate distance from your position to each candidate, looking for the minimum distance. You can use a pytagorical formula for this.
Random Solutions  
 
programming4us programming4us