Community of MapPoint and Virtual Earth Users and Developers
This is a discussion on Is there any event for when the route is changed? within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; Is there any event generated or any other way of knowing when the route has been changed?...
| |||||||
| Today's Posts | Twitter Feed | Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
|
There's the RouteAfterCalculate event, which is called with the route object as a parameter - see the Help file for documentation. I see there's also a RouteAfterOptimize() which will work in a similar manner. (you might want to trap both of them) Richard
__________________ Winwaed Software Technology LLC http://www.winwaed.com See http://www.mapping-tools.com for MapPoint Tools See the Geoweb Guru for online mapping |
| ||||
|
Those will tell you when MapPoint has modified a route. Trapping when the user has modified a route might be a bit more difficult. Perhaps check the number of waypoints in the route? Have they been added or removed? Richard
__________________ Winwaed Software Technology LLC http://www.winwaed.com See http://www.mapping-tools.com for MapPoint Tools See the Geoweb Guru for online mapping |
| |||
|
There is no event that will do that so easy |
| |||
|
How about using the SelectionChange event? You can test for TypeOf is WayPoint then do your stuff: Code: Private Sub map_SelectionChange(ByVal pNewSelection As Object, ByVal pOldSelection As Object)
If TypeOf pNewSelection Is Waypoint Then
' check to see if it's an addition or deletion, etc
If map.ActiveMap.ActiveRoute.Waypoints.Count > oldcount Then
' if it's an addition
ElseIf map.ActiveMap.ActiveRoute.Waypoints.Count < oldcount Then
' if it's a deletion
End If
End If
End Sub
|
![]() |
| Tags |
| changed, event, route |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Exporting Changed data back to Excel | kbeese | MapPoint 2006/2009 Discussion | 0 | 05-17-2005 03:57 PM |
| Where is the Quit event? | Anonymous | MapPoint 2006/2009 Discussion | 3 | 04-08-2005 07:36 AM |
| mouse down event | henemonster | MapPoint 2006/2009 Discussion | 1 | 03-31-2003 02:04 PM |
| Can the geography reference be changed in the MapP.... | Anonymous | MapPoint 2006/2009 Discussion | 1 | 05-31-2002 04:42 PM |
| Several Postcodes in England have now been changed.... | Anonymous | MapPoint 2006/2009 Discussion | 1 | 05-13-2002 07:52 AM |
Ibiza Holiday
Visit the party capital of Europe with an Ibiza holiday! Check out the deals online on UlookUbook...