Blog · Drawings · 1 Oct 2026 · 3 min read

How to merge identical parts and renumber Inventor drawings without breaking links

Hundreds of drawings become far fewer once identical parts are merged, then every code must be renumbered in the part, the drawing and the note. How an AI agent compares flat profiles, which parts it must never merge, and why renaming files on disk breaks Inventor.

Short answer: compare parts on their flat profiles extracted from the DXF, with tight tolerances, and only between parts of the same thickness and material. A person approves the groups on the 3D model. Then renumber with Inventor's SaveAs and ReplaceReference, never by renaming files, and change the code in three places: the part's Part Number, the drawing's Part Number and the note. Regenerate the DXF files afterwards.

The method for telling identical from mirrored is in finding identical and mirrored parts. This guide is the procedure around it.

Order matters: profiles first

The worst mistake is merging before the DXF profiles exist. Duplicates are compared on the profiles extracted from the DXF files, so the drawings come first.

The comparison

Two parts are identical when:

Test Tolerance
Overall size of the profile within 0.2 mm
Set of primitives: each line by its length, each arc and circle by its radius within 0.15 mm
Holes match after a rotation (0°, 180°, and 90°/270° if the outline is square) 0.01 mm
Thickness within 0.05 mm
Material the same. Steel and stainless never merge

If the holes match only after a reflection, the parts are mirrored, not identical.

Every pair is compared: 184 positions meant 16,836 pairs.

Parts that are never merged automatically

A person approves

The agent proposes the groups and shows them on the 3D model. A person approves. Approved groups go into a fixed list (member → group leader). The check after merging: the sum of quantities equals the number of starting positions. On one job the sum came out at 127 instead of 144: the group leader's own piece had not been counted (quantity = members + 1).

Renumbering

A map file lists old code → new code. New codes are contiguous, in position order, with no gaps. The register gets the delivery code and position as new columns.

The script copies each part and drawing pair into the delivery folder under the new name:

For Each oRef In oIdw.File.ReferencedFileDescriptors
    If InStr(LCase(oRef.FullFileName), LCase(sOld & ".ipt")) > 0 Then
        oRef.ReplaceReference sIptNew
    End If
Next
oIdw.PropertySets.Item("Design Tracking Properties").ItemByPropId(5).Value = sNew
For Each oNote In oSheet.DrawingNotes.GeneralNotes
    sFmt = oNote.FormattedText
    If InStr(sFmt, sOld) > 0 Then oNote.FormattedText = Replace(sFmt, sOld, sNew)
Next

Why SaveAs and not a rename on disk: each drawing points to its part by file name. Rename the part and the drawing loses it, and Inventor may keep the renamed file locked even after closing.

Regenerate the DXF files, do not copy them

After renumbering, the DXF files must be exported again. Copying the old ones left 136 drawings out of 172 with the old code, and every file was present with a normal size. Nothing looked wrong.

Do and don't

Do

Don't

Questions people ask

How much does merging save? It depends on the model. On steel structures with repeated plates it is where most of the drawings disappear.

Can the agent merge on its own? It proposes. The person who knows the job approves, because some differences are not in the geometry.