Keith
Maybe you find something usefull in this program:
(defun C:VxGetAllLength ( / CurObj CurSet FltLst TmpLgt TotLgt)
(if (< (atof (getvar "ACADVER")) 15.0)
(alert " VxGetAllLength requires AutoCAD 2000 or higher. ")
(progn
(vl-load-com)
(setq FltLst '((0.
"3DPOLY,ARC,CIRCLE,ELLIPSE,LINE,LWPOLYLINE,POLYLINE,SPLINE")
(-4 . "")
(-4 . "NOT>")
)
CurSet (cond ((ssget "I" FltLst)) ((ssget FltLst)))
TotLgt 0
)
(if CurSet
(progn
(while (setq CurEnt (ssname CurSet 0))
(setq CurObj (vlax-ename->vla-object CurEnt)
TmpLgt (vlax-curve-getDistAtParam CurObj
(vlax-curve-getEndParam CurObj)
)
TotLgt (+ TotLgt TmpLgt)
CurSet (ssdel CurEnt CurSet)
)
)
(alert (strcat "Total length of selected object(s) " (rtos TotLgt) "."))
)
)
)
)
(princ)
)
Cheers
--
Juerg Menzi
MENZI ENGINEERING GmbH, Switzerland
http://www.menziengineering.ch