试过了,可以了,谢谢楼上的。 再问个问题,,为什么我把图层名改成其他的,图层的随层色就不起作用了呢??如下: (defun c:11(/ gp) (if (= (tblobjname "layer" "a") nil) (progn (command "layer" "n" "a" "C" "1" "1" "") ) ) (setq gp (ssget)) (command "change" gp "" "p" "c" "1" "la" "a" "")) 另外,我试着定义图层的线形, (defun c:11(/ gp) (if (= (tblobjname "layer" "a") nil) (progn (command "layer" "n" "a" "C" "1" "1" "L" "center" "") ) ) (setq gp (ssget)) (command "change" gp "" "p" "c" "1" "la" "a" "L" "center" "")) 为什么不行呢? |