MapPoint Forums

MapForums

Community of MapPoint and Virtual Earth Users and Developers




Draw a route between two LONGS LATS

This is a discussion on Draw a route between two LONGS LATS within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; Hi, I m using Mappoint 2004 North America and I want two draw a route between two point(Longs and Lats) ...


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

Today's Posts Twitter Feed 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 02-16-2005
Senior Member
Black Belt
 
Join Date: Jul 2002
Posts: 5,138
Draw a route between two LONGS LATS

Hi,

I m using Mappoint 2004 North America and I want two draw a route between two point(Longs and Lats) using C#.But I could not get any thing lke get direction or getroute.....

Plz Help...

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
  #2 (permalink)  
Old 02-16-2005
Senior Member
Black Belt
 
Join Date: Nov 2004
Posts: 2,177
Hi,

This should get you started:

Code:
            double Alt = 1;
            Location Loc;
            Waypoint Way;
            Map      M = MP.ActiveMap;
            Route    R = M.ActiveRoute;

            // if there was a previous active route then we clear it
            R.Clear();

            // set start point
            Loc = M.GetLocation(Lat1, Lon1, Alt);
            Way = R.Waypoints.Add(Loc, "");
            Way.SegmentPreferences = GeoSegmentPreferences.geoSegmentQuickest;

            // set waypoints
            Loc = M.GetLocation(Lat2, Lon2, Alt);
            Way = R.Waypoints.Add(Loc, "");
            Way.SegmentPreferences = GeoSegmentPreferences.geoSegmentQuickest;

            // set end point
            Loc = M.GetLocation(Lat3, Lon3, Alt);
            Way = R.Waypoints.Add(Loc, "");
            Way.SegmentPreferences = GeoSegmentPreferences.geoSegmentQuickest;

            R.DriverProfile.StartTime = System.DateTime.Now;
            R.Calculate();
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
draw, lats, longs, route


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
Delete Numerator from waypoints when i draw a route Genamo MapPoint 2006/2009 Discussion 0 02-23-2006 03:18 AM
How I can Disable the summary of map when I Draw a Route Anonymous MapPoint 2006/2009 Discussion 1 03-09-2005 08:04 AM
Long Lats of Way points. Anonymous MapPoint 2006/2009 Discussion 1 02-22-2005 02:54 AM
how to calculate Lat/Longs for the corners of a rectangle? Anonymous MapPoint 2006/2009 Discussion 2 01-29-2005 04:18 AM
Finding Longs and Lats on mouse Move Anonymous MapPoint 2006/2009 Discussion 1 11-22-2004 03:12 AM


All times are GMT -5. The time now is 04:33 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0 RC2
MP2K Magazine
Visitor Map

Tenerife Holiday
Find a great deal on a Tenerife holiday through UlookUbook! Check out the options online...



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 55 56 57 58 59