spacer1
spacer2 1_1 1_2
2_1
 Subscribe
 The MP2K Update!
 
 
 
 Magazine
Front Cover
What's New
Articles
News
Sample Data
Gallery
Advertise
About
 Features
MapPoint 2013
Press Releases
MapPoint Forums
Companies
Link to MP2Kmag
Wish List
MapPoint Trial
Authors
 Earlier Content
Past News Items
Past What's New Announcements
 Sponsors
 Order

MapPoint 2013

Programming MapPoint in .NET

MapPoint Book

  Spatial Community
SVG Tutorials
MapPoint

Map Visitors

  MAPPOINT Q & A  

Top | Post New Question | Read All | MP2K Asks Microsoft

686 Brian P - May 24, 2002

I have a comma separated list of multiple routes. Each line in the list is a point. Each route has a starting location and ending location, and some routes have one or more waypoints, with a sequence specified in the list. The points are already pre-ordered, like so:
route A,start,123 my rd,anytown,CA
route a,end,456 my rd,anytown,CA
route b,start,789 yr rd,anytown,CA
etc.

I am writing a VB app to take this data, map it, and draw straight lines connecting all points in each route. The result would be multiple unique, nonconnecting lines, one for each route.

Is there a way in Mappoint 2002 to either
1. create/display multiple routes or a collection or routes on a single map?
2. When importing the list, have it imported in the order it is provided? Using .importdata to create the dataset, and .queryallrecords to create the recordset, when I walk the recordset using .movefirst and .movenext, the recordset is not in the order that the comma delimited list is in.

Thanks for any help anyone can provide!

Answers:
May 26, 2002
1. No. Only one route per map is allowed in MapPoint 2002. 2. This is interesting. The importdata method may have imported them in the desired order but how would you know? How can you impose order on the recordset created by the queryallrecords method? I don't think you can.

- Walt Cygan

May 31, 2002
Hi, We are a French company, we are currently writing a VB application which seems to be similar as yours... First of all we were trying to import multiple points (from 40 to 60 different points) in MapPoint, each point became a pushpin icon, and we wanted to "draw" multiple routes linking from 4 to 8 different pushpin icon to finally be able to see on the map multiple unique and non-connecting routes following the exact drawing of the roads on the map,... This seems to be impossible to do in MapPoint ! But we find an other way to do quite the same thing; in fact instead of following the exact drawing of the road , we are “drawing” lines between each pushpin icon using the “Addline” method (see Mappoint example below)... this enables us to have multiple routes on the map, having the exact distance of each route in our VB application... I hope this will help you… let us know (eric.bogaert@tasq.fr) Addline Method Dim objApp As New MapPoint.Application Dim objMap As MapPoint.Map Dim objLoc1 As MapPoint.Location Dim objLoc2 As MapPoint.Location 'application Set objMap = objApp.ActiveMap objApp.Visible = True objApp.UserControl = True ‘having two different positions Set objLoc1 = objMap.FindResults("Seattle, WA").Item(1) Set objLoc2 = objMap.FindResults("Redmond, WA").Item(1) Set objMap.Location = objLoc1 'adding a straight line between those two positions objMap.Shapes.AddLine objLoc1, objLoc2

Post New Answer / Follow-up


Google
 
MP2Kmag Internet


 Recent Discussion
 Resources


Want Your Site To Appear Here?

   © 1999-2012 MP2K. Questions and comments to: website@mp2kmag.com
  Microsoft and MapPoint 2002/2004/2006/2009/2010/2011/2013 are either trademarks or registered trademarks of Microsoft.