更改属性块中 标记属性文字RS-L,RS-R的值
;更改属性块中 标记属性文字RS-L,RS-R的值
(defun c:a2()
(setvar "cmdecho" 0)
(initget "S D")
(Setq Mapan (getkword "\n请选择:"))
(if (= Mapan "S")(setq SRZ RS-L))
(if (= Mapan "D")(setq SRZ RS-R))
(Setq abc (Strcase (Getstring "\n请输入说明:")))
(Setq Block (Ssget '((0 . "Insert")(66 . 1))))
(Setq N 0)
(Repeat (Sslength Block)
(Setq Ent (Entget (Ssname Block N)))
(Setq Ent1 Ent)
(setq SS (Cdr (Assoc -1 ent1)))
(IF (/= "SEQEND" (cdr (assoc 0 ENT)))
(WHILE (= (CDR (ASSOC 0 (SETQ ENT1 (ENTGET (ENTNEXT (CDR (ASSOC -1 ENT1))))))) "ATTRIB")
(cond
((= (CDR (ASSOC 2 ENT1)) SRZ)
(SETQ ENT1 (SUBST (CONS 1 abc) (ASSOC 1 ENT1) ENT1))
(ENTMOD ENT1))
)
)
)
(entdel SS)
(entdel SS)
(setq n (1+ n))
)
(setvar "cmdecho" 1)
(princ)
)
;是那里出现问题了,请高手指点指点
页:
[1]