Hi Mark,
Quote:
|
Originally Posted by markwilding I have been trying to find an address from gps coordinates for ages with no success, |
Try this:
Code:
double lat = 51.24987;
double lon = 4.48855;
Map map = MP.ActiveMap;
Location loc = map.GetLocation(lat, lon, 1);
loc.GoTo();
FindResults streetResults = map.ObjectsFromPoint(map.LocationToX(Loc), map.LocationToY(Loc));
foreach (object o in streetResults) {
Location streetLoc = o as Location;
if(streetLoc != null && streetLoc.StreetAddress != null)
Console.WriteLine("value " + streetLoc.StreetAddress.Value);
}