Turn routing exports into ready-to-use run sheets. Automatically.
Every week, a routing export arrives with everything the operations team needs to build driver run sheets and pack sheets. This automation reads the export, applies correct sorting and formatting, and writes the result directly into the pre-made template — without touching the conditional formatting rules the team relies on.
The problem
Manual formatting work that happened every single week.
Time lost every week
Routing exports arrived as raw data. Operations staff had to manually transfer, format, and sort it into run sheets — time that vanished before the working day had even started.
Broken formatting
Pre-made templates relied on conditional formatting rules that made run sheets readable for drivers. Manual edits regularly broke those rules, producing sheets that needed additional repair.
Pack day complexity
Some deliveries span multiple pack days, making sort order non-trivial. Manual sorting produced inconsistent results depending on who processed the file that week.
The template problem
Logistics teams build their run sheets around templates — pre-formatted Excel files where conditional formatting rules make routes readable at a glance. The problem with writing to these templates manually is that Excel's formatting is fragile. A paste into the wrong cell, a column width change, or an accidental format clear breaks the rules that make the sheet work.
This automation uses openpyxl to write data into the correct cells without touching the template's formatting layer. The template stays intact. The conditional rules survive. The output looks exactly as designed — every time.
| Seq | Pack Day | Customer | Suburb | Type | Notes |
|---|---|---|---|---|---|
| 01 | Mon AM | Jane Doe | Kardinya | Delivery | Leave at front |
| 02 | Mon AM | Jane Doe | Melville | Delivery | — |
| 03 | Mon AM | Jane Doe | Booragoon | Delivery | Call on arrival |
| Mon PM | |||||
| 04 | Mon PM | Jane Doe | Applecross | WPFR | — |
| 05 | Mon PM | Jane Doe | Ardross | Delivery | — |
What makes the sort non-trivial
A simple sort by suburb or customer name doesn't work when deliveries span multiple pack days. A Monday-packed order that delivers Tuesday has different sequencing requirements than a Monday delivery — and those rules compound across regional runs, pickup routes, and combined pack days.
The automation encodes these rules explicitly, producing a consistent sort order regardless of who runs it. The operations team gets the same output shape every week, which means drivers know what to expect and pack room staff can work to a predictable structure.
Sort logic applied
Pack day
Primary grouping — Mon AM before Mon PM
Delivery type
Standard deliveries before pickup routes
Route sequence
Stops ordered within each pack group
Edge cases
Combined pack days resolved deterministically
Solution overview
Four steps. Same output every week.
Read routing export
Load the raw routing data from the export file — stops, customers, delivery types, and pack day information.
Clean and sort
Apply robust sorting rules for combined pack days. Normalise field formats and resolve edge cases that trip up manual processing.
Write to template
Populate the pre-made Excel template — sequence, pack day groupings, customer fields, and driver notes — without touching the conditional formatting rules.
Ready to use
Run and pack sheets land in the output location, correctly formatted and sorted, ready for the team before the working day begins.
Technologies used
Have a manual weekly process that produces the same output every time?
Let's automate it — consistent output, no formatting rework, and time back for the people who matter.