Length Totals by Layer (PLEN)
eplisp, the free multilingual LISP library
| Openly licensed; the original file is hosted here together with its license. | |
… Rate this tool: | |
| Commands | PLEN |
|---|---|
| Category | Measuring and Totals |
| Author | BGol Community |
| Source | thevijayparmar/bgol-cad-lisps |
| License | MIT |
| Requirements | AutoCAD (full version; not LT), BricsCAD, ZWCAD. Uses Visual LISP ActiveX (vla/vlax) functions. |
| Prompt language | English |
| Files | PLLENTAB-bgol.lsp (5 KB) |
| Added | 2026-10-26 |
| Download the original fileSource repository | |
Totals the lengths of selected lines and polylines layer by layer and writes the per-layer sums and a grand total as text in the drawing.
PLEN is a quantity takeoff helper from the BGol Community library. It measures every selected LINE and LWPOLYLINE, groups the lengths by layer and places a short summary in the drawing, which is useful when pipes, cables or road edges are drawn on separate layers.
Overview
Lengths are read along the curve, so arc segments inside polylines count at their true length. The output is a column of single-line TEXT rows starting at the picked point: a title, a header, one row per layer with its total (three decimals) and a final GRAND TOTAL row. All rows go on the layer BGOL-PLEN, which the command creates in blue if it does not exist.
How to use it
- Load PLLENTAB-bgol.lsp with APPLOAD (or drag it onto the drawing window).
- Type PLEN and press Enter.
- Select the lines and polylines to total and press Enter.
- Pick the point where the summary should start; the rows are written downward from there.
Notes and limitations
- Only LINE and LWPOLYLINE objects can be selected; arcs, circles, splines and old-style 2D/3D POLYLINE objects are ignored.
- Text height is fixed at 2.5 drawing units and row spacing at 1.8 times that; changing them requires editing the code.
- The result is plain TEXT rows, not an AutoCAD TABLE, and it does not update when the geometry changes.
- Creates the layer BGOL-PLEN if it is missing.
- The repository was published in 2026; test on a copy of the drawing first.
Source and license
This tool is not made by eplisp. The file is published unchanged under its author's license; copyright stays with the author.
References
- Source repository: thevijayparmar/bgol-cad-lisps – https://github.com/thevijayparmar/bgol-cad-lisps/tree/3acbe32f71b489f4c81dcd9372f989591a9be858/Polyline%20Lisps/Calculate%20Length
- Author: BGol Community – https://bgol.in/
- License: MIT – https://github.com/thevijayparmar/bgol-cad-lisps/blob/3acbe32f71b489f4c81dcd9372f989591a9be858/LICENSE
Found a mistake, or are you the author of this tool? Request a correction or removal