Community of MapPoint and Virtual Earth Users and Developers
This is a discussion on Is it possible to calculate latitud/longitud through address within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; Hi there, Is it possible to calculate latitude and longitude with the help of address. Say you've street address, city, ...
| |||||||
| Today's Posts | Twitter Feed | Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| Is it possible to calculate latitud/longitud through address Is it possible to calculate latitude and longitude with the help of address. Say you've street address, city, country, post code etc. and you've to calculate the longitude and latitude. Please guide and oblige! Regards
__________________ Learn from cradle to the grave |
| |||
|
Hi, Yes this is good possible. Because each address has a collection of Location objects, however you need a thrick. The CalcPos routine will you find somewhere on this forum (try search on CalcPos). Original in VB fro m Gilles, but various C# copies are posted too. This will start you: Code: FindResults results = mp.ActiveMap.FindAddressResults(street, city, othercity, region, zip, country);
if (results.ResultsQuality <= GeoFindResultsQuality.geoAmbiguousResults)
foreach (object o in results) {
Location loc = o as Location;
if (loc != null) {
double lat;
double lon;
Pushpin PP = mp.ActiveMap.AddPushpin(loc, "");
PP.GoTo();
MPTools.CalcPos(mp.ActiveMap, loc, out lat, out lon);
__________________ rgds, Wilfried Mestdagh www.mestdagh.biz MapPoint coding demo Order MapPoint 2009 with Routing and User Tools Spreadsheet |
![]() |
| Tags |
| address, calculate, latitud or longitud |
| ||||
| Posted By | For | Type | Date | |
| Is it possible to calculate latitud/longitud through address - MapPoint Forums | This thread | Refback | 01-29-2009 09:20 AM | |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to retrieve complete address from longitudes and latitud | Learner | MapPoint 2006/2009 Discussion | 14 | 01-04-2007 08:40 AM |
| How to retrieve nearest city from longitudes and latitud | fsarraj | MapPoint 2006/2009 Discussion | 3 | 03-08-2006 12:22 PM |
| Calculate distances | Anonymous | MapPoint 2006/2009 Discussion | 1 | 11-18-2004 10:58 AM |
| Calculate route | Anonymous | MapPoint 2006/2009 Discussion | 0 | 07-03-2003 02:25 AM |
| I am having trouble... I am trying to calculate r.... | Anonymous | MapPoint 2006/2009 Discussion | 1 | 07-10-2002 10:30 AM |
Hurghada Holiday
Enjoy sunny Egypt when you book a Hurghada holiday through UlookUbook at a good price!