오랜만에 다시한번 도움 요청 드립니다.
해외 사이트에서 자동으로 ORDINATE 작업하는 리습인데 실행이 안되네요
고수님들 한번 봐주실수 있을까요??
(defun c:DDDD ( / ss pt i ed n) ; Dim Ordinate Origin set
; routine is appliead on pre-selected selection set
; or to all Ordinate dimensions in the drawing
(if (and (setq ss (cond ((ssget “_I” ‘((0 . “DIMENSION”))))
((ssget “_A” (list ‘(0 . “DIMENSION”) (cons 410 (getvar ‘CTAB)))))))
(setq pt (getpoint “nNew origin: “))
(setq pt (trans pt 1 0))
(setq n 0)
)
(repeat (setq i (sslength ss))
(setq ed (entget (ssname ss (setq i (1- i)))))
(foreach e ed
(if (and (= (car e) 100)
(wcmatch (cdr e) “*Ordinate*”)
(setq n (1+ n)))
(entmod (subst (cons 10 pt)
(assoc 10 ed)
ed))))))
(sssetfirst nil nil)
(if (> n 0) (princ (strcat “n” (itoa n) ” ordinate dimentions modified.”)))
(princ)
)
(princ “nType ‘DOOrigin’ to run the command. Applied on the Pre-Selection OR on ALL Ordinate Dims.”)
(princ)