本帖最后由 ZZXXQQ 于 2014-11-27 19:57 编辑
 - (defun c:tt ()
- (while (and (setq s1 (entsel "\n选择多段线: "))
- (setq ent (entget(car s1)))
- (= (cdr(assoc 0 ent)) "LWPOLYLINE"))
- (setq ptlst (list))
- (foreach x ent (if (= (car x) 10) (setq ptlst (cons (cdr x) ptlst))))
- (princ (setq n (sslength(ssget "WP" ptlst '((0 . "CIRCLE"))))))
- )
- (princ)
- )
|