View Single Post

  #2 (permalink)  
Old 11-03-2004
John Meyer's Avatar
John Meyer John Meyer is offline
Senior Member
Blue Belt
 
Join Date: Jul 2002
Posts: 479
This is a sample from the help file.

Code:
Sub ClearCalculatedRoute()

  Dim objApp As New MapPoint.Application
  Dim objMap As MapPoint.Map
  Dim objRoute As MapPoint.Route

  'Set up the application
  Set objMap = objApp.ActiveMap
  Set objRoute = objMap.ActiveRoute
  objApp.Visible = True
  objApp.UserControl = True

  'Add route stops and calculate the route
  objRoute.Waypoints.Add objMap.FindResults("Seattle, WA").Item(1)
  objRoute.Waypoints.Add objMap.FindResults("Redmond, WA").Item(1)
  objRoute.Calculate

  'Now clear the route
  objRoute.Clear

  End Sub
__________________
John
http://www.support-pc.com

Order MapPoint 2006 Here
https://secure.mp2kmag.com/?refer=support-PC
Reply With Quote