- (defun c:tt ()
- "统计块名称含灯的块"
- (if (setq ss (ssget "x" '((0 . "INSERT") (66 . 1))))
- (progn
- (setq lst(vl-remove-if-not '(lambda (x) (setq a (mapcar 'last (xyp-Att2list x))) (vl-some '(lambda (x) (vl-string-search "灯" x)) a))(xyp-Ss2List ss)))
- (princ (strcat "\n一共选择了< " (itoa (length lst)) " >个块名称含灯的块"))
- )
- )
- (princ)
- )
|