luowy 发表于 2008-10-20 14:43:00
<p>(defun c:aaa()<br/>(command "_mline" "st" "3气" "pause")<br/> <br/>(while (= (logand (getvar "CmdActive") 1) 1) (command pause))<br/>(command "explode" (entlast) "")<br/> (setq ll (cons 8 "0")<br/> yl (cons 8 "1")<br/> ysl (cons 8 "2")<br/> zkl (cons 8 "3")<br/> ;ol (cons 62 1)<br/> )<br/> (setq ss (ssget "p")) ;获得选集<br/> <br/> (setq n 0)<br/> (repeat (sslength ss)<br/> (setq ents (entget (ssname ss n))<br/> pp (cdr (assoc 62 ents)))<br/> (cond<br/> ((= pp '1) (entmod (subst yl ll ents)))<br/> ((= pp '6) (entmod (subst zkl ll ents)))<br/> ((= pp '230) (entmod (subst ysl ll ents)))<br/> )<br/> ;(entmod ents)<br/> (setq n (1+ n))<br/> <br/> );repeat<br/> )</p><p>(defun *error* (msg)<br/> (princ "Failure at:")<br/> (princ msg)<br/> (princ))</p><p></p><p>如上可以解决问题,谢谢各位的帮助~~</p>
页:
1
[2]