(defun ttrtplines () (command "area" "e" sn) (setq tarea (+ tarea (getvar "area"))) (ssdel sn ss1) ) (defun ttrtsplines () (command "area" "e" sn) (setq tarea (+ tarea (getvar "area"))) (ssdel sn ss1) ) (DEFUN C:totalarea (/ tarea ss1 sn ent sn2 et) (setq cmdecho (getvar "cmdecho")) (setvar "cmdecho" 0) (setq tarea 0) (prompt "\nSelect only those entities you want for total area: ") (setq ss1 (ssget)) (while (> (sslength ss1) 0) (setq sn (ssname ss1 0)) (setq ent (entget sn)) (setq et (cdr (assoc '0 ent))) (cond ((= et "LWPOLYLINE") (ttrtplines)) ((= et "POLYLINE") (ttrtplines)) ((= et "SPLINE") (ttrtsplines)) ((or (/= et "LWPOLYLINE") (/= et "POLYLINE") (/= et "SPLINE") ) (ssdel sn ss1) ) ) ) (SETQ ACRES (/ TAREA 43560)) (alert (strcat "\nThe Total AREA of Selected Polylines is: " (rtos tarea 2 2) " SQ. FT. --- " (RTOS ACRES 2 3) " AC.")) (setvar "cmdecho" cmdecho) (princ) )