Any body know how to calculate de starting and finished point on a route segment the link below has a detail picture
http://home.earthlink.net/~hidroela/car%20system.htm
Any help would be appreciated
Best regards Hidroilio
This is a discussion on how to calculate de starting and finished point on a route within the MapPoint Desktop Discussion forums, part of the Map Forums category; Any body know how to calculate de starting and finished point on a route segment the link below has a ...
Any body know how to calculate de starting and finished point on a route segment the link below has a detail picture
http://home.earthlink.net/~hidroela/car%20system.htm
Any help would be appreciated
Best regards Hidroilio
Hi Hidroilio,
Yes. Each Direction object has a Location member. You find code to calcluate latutude and longitude from out of Location object here: http://www.mp2kmag.com/articles.asp?...xtract.lat.lon
rgds, Wilfried Mestdagh
www.mestdagh.biz
www.comfortsoftware.be
www.expertsoftware.be
MapPoint coding demo
MapPoint 2011 available, buy now
Hi Wilfried I think that I was not explicit enough below is a link to a detail figure of What I am trying to accomplish
I need to calculate the latitude and longitude of the point 1,2,3,4
When I calculate the route I only provide points 1 and 2
Point 1 thought a gps receiver and point 2 as an address
Best regards Hidroilio
http://home.earthlink.net/~hidroela/map.gif
Hi Hidroilio,
I think I understeand right (I hope), but I also think I explained bad
Now you set start, via and end points. Then you calculate the route:Code:Map M = MP.ActiveMap; Route R = M.ActiveRoute; R.Clear();
Here every Direction has a property Location. From this one you can calculate lat/long of it. Your GPS coordinates compare to them and you can give appropriate instructions. Of course you have to put each Direction point in a dataset or so, and know if you past it or not, and also if driver choose another road.Code:Directions dir = R.Directions; foreach (MapPoint.Direction d in dir) {
Does I make more sence her ?
rgds, Wilfried Mestdagh
www.mestdagh.biz
www.comfortsoftware.be
www.expertsoftware.be
MapPoint coding demo
MapPoint 2011 available, buy now
Hi Wilfried
Thanks for you replay, now I understand what you was trying to explain on your last post but I already got this answer in another forum with the difference that yours is a liter bet more elaborated
But like Mr. guilles point out on that forum
<<Hmm, while there is a Location property in the "Direction" object, I'm
afraid it will only provide the center of the corresponding segment
(if you're lucky), not the beginning or end ...>>>>
that approaches did not really help me out to much first at all it did not return the edges instead the middle point and some times it is not accurate
any ways thanks
best regards
Hidroilio
this is a picture of and example
http://home.earthlink.net/~hidroela/map2.gif
Hi Hidroilio,
If you need additional help just yell here![]()
rgds, Wilfried Mestdagh
www.mestdagh.biz
www.comfortsoftware.be
www.expertsoftware.be
MapPoint coding demo
MapPoint 2011 available, buy now
There are currently 1 users browsing this thread. (0 members and 1 guests)