Skip to content

Shapes and Colour

This group turns a worksheet into a visual status diagram: name the blocks on a site layout, read colour codes out as numbers, then recolour every shape at once from a progress formula. It is for the site engineer who has to republish a colour-coded progress map every week without clicking each object.

Everything lives on tab DVD Addin → group Graphics: the main button Color Shapes, and the rest under Shape Menu.

Commands in this group

CommandWhat it does
Color ShapesRecolour many shapes from a two-column map: shape name → RGB code
Color RectsRead the RGB code in each cell and draw a matching rectangle on top of it
List ShapesWrite every shape name on the active sheet down a column from the selected cell
Rename ShapesBatch rename from a two-column map: old name → new name
Get PositionLook coordinates up by shape name and paste them as Top;Left (points)
Get Color CodeRead a cell's fill colour and write the numeric RGB code into that cell
Auto ClickRecord and replay a mouse-click sequence — see Auto Click

Color Shapes and Auto Click need a valid DVDAddin account (Standard or PRO, fully available during the Trial); the rest work out of the box.

The picture commands share the Graphics group but are covered separately in Insert Pictures.

Building a colour-coded progress layout

The first four commands chain together: list the names → standardise the names → capture the colours → repaint.

  1. Prepare the drawing. Paste the zone layout into the sheet as shapes — one shape per slab bay or zone.
  2. Get the names out. Select an empty starting cell (say K5) and run List Shapes. The add-in writes one name per row and reports "Listed N shapes". It overwrites whatever sits below the starting cell, so pick clear space.
  3. Standardise the names. Excel's own names (Rectangle 27) are useless. Add a new-name column beside them, run Rename Shapes, and drag over the two columns when the picker asks for "2-col range: old shape name (left), new shape name (right)".
  4. Capture the approved colours. Copy the legend cells into a scratch column and run Get Color Code there to turn fills into numbers. Never run it on the master table — it overwrites the cells it reads.
  5. Build the colour formula column immediately to the right of the shape-name column.
  6. Repaint. Run Color Shapes and drag over the two columns when the picker asks for "shape names left, RGB codes right". The toast reads "Coloured N shapes (errors X)" — the number in brackets is the rows skipped because the colour cell was not numeric.
  7. Check the layout (optional). Select the shape-name column, run Get Position, and pick a target column for the Top;Left strings — shapes sharing a Top are aligned horizontally.

Next week you only edit the status column and repeat step 6.

Example

A level-3 slab-pouring layout, one shape per bay named BAY_A1, BAY_A2… The status column sits in F, and the mapping table is the two adjacent columns G (shape name) and H (RGB code):

F — StatusG — Shape nameH — RGB code
PouredBAY_A15296274
PouredBAY_A25296274
In progressBAY_B165535
Not startedBAY_B212632256

Formula in H5: =IF(F5="Poured",5296274,IF(F5="In progress",65535,12632256)).

Run Color Shapes, drag over exactly G5:H40, click OK. The whole layout repaints in one click: green for poured, yellow for the bay under way, grey for not yet started. Next week, edit column F and click again.

For a grid-style heat map instead of a layout drawing, use Color Rects: point it straight at the cells holding RGB codes and it draws one colour block per cell, sized to the cell.

Tips and caveats

  • Colour codes must be numbers, packed the Excel way: Red + Green×256 + Blue×65536. Text, blanks and #RRGGBB hex strings count as errors and are skipped.
  • Shape names must match exactly. One wrong character silently skips the row. Names should also be unique per sheet — duplicates mean the command only ever finds the first shape.
  • Everything Color Shapes and Color Rects paint gets a fixed 50% transparency; there is no option to change it.
  • Color Rects sets the cell number format to ;;; to hide the code, and re-running it over the same range stacks another layer of shapes — to clean up, use Home → Find & Select → Go To Special → Objects, then delete.
  • Get Color Code overwrites the cell contents and cannot read colours produced by conditional formatting; a No Fill cell returns 16777215 (white), not a blank.
  • Every command here works on the active sheet only and cannot be undone with Ctrl+Z. Hold ESC to stop midway; whatever was already processed stays.
  • Get Position returns the single text string Top;Left, not two numbers — split it with Text to Columns using the ; delimiter.

See also

  • Insert Pictures — the image commands in the same Graphics group.
  • Auto Click — the last entry in Shape Menu, recording and replaying mouse clicks.
  • Gantt Chart — the schedule that feeds the status column behind the colour formula.
  • Move/Resize — snap a single shape or picture into its cell once the layout is set.

Released under DVDAddin License.