Pickups and deliveries

MagiCat
05-22-2006, 08:42 PM
I have a specialized application that I need to develop and was wondering if anyone has seen anything close to it already created.

One of our drivers has to do pickups and deliveries of garbage containers, 3 yard, 5 yard, 6 yard, and 8 yard sizes.

Generally the driver will leave in the morning with a certain mix of containers which is his best guess as to what will get him the furthest during the day without having to come back. His route ends up being a mix of looking at a Streets and Trips printout as well as his own judgement with improvisation throughout the day.

What I'm trying to do is come up with an optimal route which lets him complete his route in the least amount of time, factoring in trips back to the yard to either pick up more containers or drop off extraneous containers.

As for quantity, on an average day we're talking about 35 dropoffs and about 25 pickups in a given day though it could be as high as 100 total.

Anyone have any ideas on how to go about this, I've programmed in Excel, Word, Access and have crossed programmed small applications using multiple programs, just wondering if this is something that sounds doable with MapPoint 2006.

nmilne
06-04-2006, 03:00 PM
i have done a job delivery program in msaccess
this bit of code will help you get started in ms access
Option Compare Database

Private objMap As MAPPOINT.MappointControl
Private objRoute As MAPPOINT.Route
Private objSA As MAPPOINT.StreetAddress
Private objPush As Pushpin
'Private objway As Waypoints
Private oLoc As Object


Private Sub cmdPlot_Click()
If txtAddress <> "" Then
ApplyPoint
End If
End Sub


Private Sub Form_Load()
Set objMap = Mapctl.Object
objMap.NEWMAP geoMapEurope
End Sub


Public Function ApplyPoint()

If objMap Is Nothing Then Set objMap = Me!Mapctl.Object
Set objSA = objMap.ActiveMap.ParseStreetAddress(PICKUPADDRESS & " , " & PICKUPTOWN & " , " & PICKUPCOUNTY & " , " & PICKUPPOSTCODE)
Set oLoc = objMap.ActiveMap.FindAddressResults(objSA.Street, objSA.City _
, , objSA.Region, objSA.PostalCode)

If Not oLoc Is Nothing And oLoc.ResultsQuality <> geoNoResults Then

Set objPush = objMap.ActiveMap.AddPushpin(oLoc(1).Location, Me.PICKUPCUSTOMER)
objPush.BalloonState = geoDisplayName
objMap.ActiveMap.ActiveRoute.Waypoints.Add oLoc(1) 'Adds Awaypoint to map
objPush.Location.GoTo
Set objPush = Nothing
Set oLoc = Nothing
End If

End Function

 
Web mp2kmag.com
mapforums.com