MapPoint Forums

MapForums

Community of VE/MapPoint Users and Developers




Is there any event for when the route is changed?

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?...


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

Register Blogs FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 08-30-2005
Junior Member
Yellow Belt
 
Join Date: Jun 2004
Posts: 27
Is there any event for when the route is changed?

Is there any event generated or any other way of knowing when the route has been changed?
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-30-2005
Winwaed's Avatar
Mapping-Tools.com
Red Belt
 
Join Date: Feb 2004
Posts: 787
Blog Entries: 5
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
Pre-Order MapPoint 2009 today: http://www.mapping-tools.com/mappoint2009
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-30-2005
Winwaed's Avatar
Mapping-Tools.com
Red Belt
 
Join Date: Feb 2004
Posts: 787
Blog Entries: 5
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
Pre-Order MapPoint 2009 today: http://www.mapping-tools.com/mappoint2009
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-30-2005
Junior Member
Yellow Belt
 
Join Date: Jun 2004
Posts: 27
Thanks for that but I really need to know when the user either removes or adds an item to the route.
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 11-25-2005
Junior Member
White Belt
 
Join Date: Nov 2005
Posts: 10
Send a message via ICQ to oschulz
There is property called "IsCalculated". Thats what you need.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #6 (permalink)  
Old 11-25-2005
Junior Member
Yellow Belt
 
Join Date: Jun 2004
Posts: 27
I needed an actual event not a property, i.e. to be notified as soon as a waypoint is added or removed and what the waypoint was.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #7 (permalink)  
Old 11-25-2005
Junior Member
White Belt
 
Join Date: Nov 2005
Posts: 10
Send a message via ICQ to oschulz
There is no event that will do that so easy . I have used the OnAfterRedraw-event. When a waypoint is added, the map is redrawed. Maybe you use an own temp route list and compare it with the Mappoint routelist. Then you have the waypoint position which is changed.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #8 (permalink)  
Old 11-25-2005
Junior Member
Yellow Belt
 
Join Date: Jun 2004
Posts: 27
thanks for that suggestion - ii will try it out
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #9 (permalink)  
Old 11-28-2005
Junior Member
White Belt
 
Join Date: Nov 2005
Posts: 10
Send a message via ICQ to oschulz
I have try out the SelectionChange event, thats better for your Problem i think. That event occurs, for example when a new waypoint is added .
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #10 (permalink)  
Old 11-28-2005
Junior Member
Yellow Belt
 
Join Date: Jan 2003
Posts: 17
Send a message via ICQ to brianmcg
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
__________________
Brian McGrath
CAD North Inc.
http://www.cadnorth.com
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


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
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


All times are GMT -5. The time now is 05:50 PM.


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

Exeter Flights
Visit Holiday Hypermarket online to find all the essential information about Exeter Airport and Exeter flights. Booking is quick, easy and cheap with Holiday Hypermarket.

Portugal Weather
Check out Portugal Weather - Travel Counsellors details information on Portugal including, weather, flights and accommodation.

Italy Holiday
An Italy Holiday is full of interesting stuff for the casual tourist and even more for the educated visitor. Check out the latest great deals at dealchecker.co.uk.

Holidays to Antigua
The Holiday Place has fantastic deals on holidays to Antigua. Visit our website to view special offers on holidays to the Caribbean.

Cheap Portugal Holidays
Want to know what the best time to book cheap Portugal holidays is? Well have a look on ulookubook.com for some useful information to save your cash. Golf, tennis and cycling are all very popular here.

All inclusive holiday
Travel.co.uk is a travel comparison service which makes it easy to search and find your all inclusive holiday.

Cheap Holidays in Lanzarote
Now's the time to get up and go visit the Canary Islands! View cheap holidays in Lanzarote only at On The Beach.


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