- (defun c:tt ();二次过滤选择集
- (setq ss (ssget '((8 . "layer7") (0 . "LWPOLYLINE"))))
- (setq ii 0)
- (repeat (sslength ss)
- (setq ss0 (ssname ss ii)
- ii (1+ ii)
- )
- (setq ptlist (Hx-pl-list ss0))
- (setq ss++ (ssget "cp" ptlist))
- (setq ss++ (ssdel ss0 ss++))
- (setq i 0)
- (repeat (sslength ss++)
- (setq ss0++ (ssname ss++ i)
- i (1+ i)
- )
- (setq Obj (vlax-ename->vla-object ss0++))
- (vla-offset Obj -5)
- );repeat-第二个
- );repeat-第一个
- )
- (defun Hx-pl-list (SS0 / e elist ptlist) ;端点列表
- (setq elist (entget SS0))
- (foreach n elist
- (if (= 10 (car n))
- (setq ptlist (cons (cdr n) ptlist))
- )
- )
- (reverse ptlist)
- )
|