CADLisp Tools

CAD discipline

Mechanical & Manufacturing AutoLISP tools and downloadable LISP routines

Find AutoLISP routines for mechanical and manufacturing drawings, block attributes, BOM data, hole coordinates, and annotation.

Each tool page includes its CAD command, readable source code, a direct .LSP download, setup instructions, a worked example, and known limitations.

Download and review

24 Mechanical & Manufacturing routines

Search the full AutoLISP library →
Geometry & Polylines6 disciplines

Total Polyline Length

Calculate the combined length of selected 2D and legacy polylines.

⌘ TOTPLENBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Geometry & Polylines6 disciplines

Closed Polyline Area

Sum the area of selected closed polylines and skip open ones.

⌘ CLOSEDARIntermediateCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Text & Numbering6 disciplines

Incremental Text Numbering

Renumber TEXT and MTEXT objects in the exact order you select them.

⌘ NUMTEXTBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Text & Numbering6 disciplines

Add Prefix to Selected Text

Add a fixed prefix to selected TEXT and MTEXT objects.

⌘ ADDPREFIXBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Standards & QA6 disciplines

Drawing Layer Checker

Report objects on Layer 0 or Defpoints and list locked, frozen, or off layers.

⌘ LAYERCHECKIntermediateCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Text & Numbering6 disciplines

Add Suffix to Selected Text

Append a fixed suffix to selected TEXT and MTEXT objects.

⌘ ADDSUFFIXBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Data Extraction4 disciplines

BOM from Block Attributes

Count selected blocks by one chosen attribute value.

⌘ BLOCKBOMAdvancedCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Dimensions & Annotation6 disciplines

Coordinate Label X/Y

Create a WCS X/Y text label at a picked coordinate.

⌘ XYLABELBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Text & Numbering6 disciplines

Change Text Case

Convert selected TEXT and unformatted MTEXT to upper- or lowercase.

⌘ TEXTCASEBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Standards & QA6 disciplines

Detect Duplicate Text

Select duplicate TEXT or MTEXT at matching insertion points.

⌘ DUPTEXTIntermediateCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Blocks & Attributes4 disciplines

Equipment Tag Numbering

Write a prefix and sequential number into a chosen block attribute.

⌘ EQTAGNOAdvancedCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Selection & Editing6 disciplines

Select Objects by Layer

Select objects on an existing named layer in the active model or paper-space layout.

⌘ SELBYLAYERBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Blocks & Attributes6 disciplines

Select Same Blocks

Select same-name block references, including dynamic block references.

⌘ SELSAMEBLOCKSIntermediateCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Data Extraction6 disciplines

Export Block Attributes to CSV

Export selected block names and attribute tag/value pairs to a CSV file.

⌘ ATTCSVAdvancedCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Data Extraction3 disciplines

Hole Coordinate Table

Create a simple MTEXT list of WCS circle-center coordinates.

⌘ HOLETABLEIntermediateCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Drawing Cleanup6 disciplines

Purge/Audit Helper

Run CAD audit and one all-item purge pass only after explicit confirmation.

⌘ CLEANHELPIntermediateCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Blocks & Attributes6 disciplines

Count Selected Blocks

Summarize selected block references by name in the command line.

⌘ COUNTBLOCKSIntermediateCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Dimensions & Annotation6 disciplines

Set Text Height

Set one positive height on selected TEXT and MTEXT objects.

⌘ SETTXTHBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Dimensions & Annotation5 disciplines

Area Label

Place a text label containing a selected closed polyline's area.

⌘ AREALABELIntermediateCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Drawing Cleanup6 disciplines

Delete Empty Layers

Preview and optionally delete unused, non-protected layers.

⌘ DELEMPTYAdvancedCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Dimensions & Annotation3 disciplines

Hole Coordinate Label

Label the WCS center X/Y coordinates of selected circles.

⌘ HOLEXYBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Geometry & Polylines6 disciplines

Distance Between Points

Report the 2D and 3D distance between two picked points.

⌘ PTDISTBeginnerCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Text & Numbering6 disciplines

Find & Replace Selected Text

Replace matching text inside a deliberate selection of TEXT and MTEXT objects.

⌘ REPTEXTIntermediateCAD support: not tested
Updated Sep 18, 2026VIEW TOOL →
Layers6 disciplines

Assign Selection to Existing Layer

Move selected objects onto an existing layer with validation and no layer creation.

⌘ TOLAYERBeginnerCAD support: not tested
Updated Sep 12, 2026VIEW TOOL →