MapPoint Forums

MapForums

Community of VE/MapPoint Users and Developers




Need to get a return address from MapPoint

This is a discussion on Need to get a return address from MapPoint within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; Hi, I use the folowing code to get a MapPoibt.Location from MapPoint, nd it works fine. But I need to ...


Go Back   MapPoint Forums > Map Forums > MapPoint 2006/2009 Discussion

Register Blogs FAQ Members List Calendar Search Today's Posts Mark Forums Read



Click here to register

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 08-02-2006
Senior Member
Green Belt
 
Join Date: Jul 2005
Posts: 105
Need to get a return address from MapPoint

Hi,

I use the folowing code to get a MapPoibt.Location from MapPoint, nd it works fine. But I need to have a loko at the actual address it is returning.

I have found a problem in MapPoint 2004, which is my latest version I have. When I attempt to get "256 Pleasant St, Arlington, MA", for example, I get the same location as if I asked for "1 Pleasant St, Arlington, MA". So I decided to have a look at what MapPoint is returning to me. The MapPoint program with the WIndws GUI returns "Pleasant St, Arlington, MA". So I want to be able to examine the address of what's coming back to me.

I knw I ned to iterate through results.GetEnumerator() but I'm not sure how.

Thanks,
Bob

MapPoint.Route mpRoute = mpMap.ActiveRoute;
MapPoint.FindResults results = mpMap.FindAddressResults( street, city, "", state, "", 244 );

//SetSpeedProfile( handles, mpRoute );
handles.MapPointFindResults = results;
if (results.Count >= 1 && results.ResultsQuality == resultsQuality )
{
mpRoute = mpMap.ActiveRoute;
IEnumerator item = results.GetEnumerator();
item.Reset();
item.MoveNext();
return (MapPoint.Location)item.Current;
}
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #2 (permalink)  
Old 08-02-2006
Senior Member
Black Belt
 
Join Date: Nov 2004
Posts: 2,112
Hi Bob,

Quote:
I knw I ned to iterate through results.GetEnumerator() but I'm not sure how
I'm not sure I understeand your question but: use foreach()
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3 (permalink)  
Old 08-05-2006
Senior Member
Green Belt
 
Join Date: Jul 2005
Posts: 105
yes, but

Wilfried,

Thanks. Stupid Me! I was using this kind of loop:

foreach (MapPoint.Location in results)
{
}

I forgot to unclude the actual variable.

C:\Texselogic\Projects\DMS\Trip.cs(293): Type and identifier are both required in a foreach statement

Thanks.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #4 (permalink)  
Old 08-05-2006
Senior Member
Green Belt
 
Join Date: Jul 2005
Posts: 105
Multiple addresses for a given address

Hi,

I have a major problem I hope I can find a solution for. I'm going live in a pizza shop next week at the following address:

1000 US 80
Haughton, LA

But when I enter the address, it shows me two versions of the address, with 7 miles in between! Please check it out. I never saw this before.

I'm using MapPoint 2004. Is this fixed in a later version? If so, I wonder how I could get an update. I have the MSDN subscription for 2004, but I have no funds to update it. That's what this test is all about.

Any suggestions?

Thanks,
Bob
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5 (permalink)  
Old 08-06-2006
Senior Member
Green Belt
 
Join Date: Jul 2005
Posts: 105
got it

Actually, in that case, MapPoint returned the reult type as ambiguous, so in the case I just use a web service as a backup.

No reply needed.

Thanks,
Bob
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Tags
address, mappoint, return


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Return Pushpin Symbol Anonymous MapPoint 2006/2009 Discussion 1 04-27-2005 03:12 PM
Return surrounding Zip Codes johnweidauer MapPoint 2006/2009 Discussion 0 02-11-2004 05:58 PM
Can Mappoint 3.0 SDK return Latitude Longitude coordinates? Anonymous MapPoint 2006/2009 Discussion 1 01-27-2004 06:56 PM
newbie wants help in getting mappoint to return coordinates Anonymous MapPoint 2006/2009 Discussion 1 05-02-2003 03:36 PM
When I enter just a zipcode in MapPoint, it return.... Anonymous MapPoint 2006/2009 Discussion 1 05-30-2002 09:43 PM


All times are GMT -5. The time now is 05:34 AM.


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
MP2K Magazine
Visitor Map


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54