(vl-load-com)
(vlr-command-reactor nil ‘((:vlr-commandWillStart . start_Dimm)))
(vlr-command-reactor nil ‘((:vlr-commandEnded . end_Dimm)))
(vlr-command-reactor nil ‘((:vlr-commandCancelled . cancel_Dimm)))
(defun start_Dimm (calling-reactor start_DimmInfo / the_Dimmstart)
(setq OldLayer (getvar “CLAYER”))
(setq laynam “DIM”)
(cond ((= (wcmatch (nth 0 start_DimmInfo) “*DIM*”) T) (setvar “CLAYER” laynam)))
(princ)
)
(defun end_Dimm (calling-reactor end_DimmInfo / the_Dimmend)
(cond ((= (wcmatch (nth 0 end_DimmInfo) “*DIM*”) T) (setvar “CLAYER” OldLayer)))
(princ)
)
(defun cancel_Dimm (calling-reactor cancel_DimmInfo / the_Dimmcancel)
(cond ((= (wcmatch (nth 0 cancel_DimmInfo) “*DIM*”) T) (setvar “CLAYER” OldLayer)))
(princ)
)
(princ)
도면 로드되고 치수입력시 dim 이라는 레이어로 변경 되고 이전 에 사용한 레이어로 돌아가는데
한두번은 잘되다가 여러도면 띄우다가 보면 치수레이어 뽑고는 이전레이어로 돌아가질 않네요 …
한번봐주세요
좋은 자료 감사합니다..
아… 저도 이런거 찾고 있었는데… 감사합니다 ^-^