感谢大佬
由于输出的ACXXXX对于大部分人来说不够直观,后边加段转换为直观版本的函数
(defun c:tt(/ f a)
(setq f (open (strcat(getvar "dwgprefix")(getvar "dwgname"))"r"))
(setq a (read-line f))
(cond
((= a "AC1015") (setq a "2000"))
((= a "AC1018") (setq a "2004"))
((= a "AC1021") (setq a "2007"))
((= a "AC1024") (setq a "2010"))
((= a "AC1027") (setq a "2013"))
((= a "AC1032") (setq a "2018"))
)
(princ a)
(princ)
)