你怎么跳到最后?
在一个函数中,你如何使它不进一步?下面的代码没有退出该函数。(if (or (= dir (getroot)) (= dir (strcat (getroot) "\\Titleblocks")))
(progn
(princ "\nHey you’re not allowed to delete files from this folder! ")
end
)
)
显然,结局并不像我想象的那样。 尝试:
(exit)
or
(quit)
亨里克
非常感谢你! 不客气!
亨里克 请注意,一个好的编程实践是在使用退出/退出进行更干净的退出时添加错误陷阱。或者可以按如下方式构建代码,尽管这可能会使代码过载。
(if (not (or (= dir (getroot))
(= dir (strcat (getroot) "\\Titleblocks"))))
(progn
;;;your main code here
)
(progn
(princ "\nHey you’re not allowed to delete files from this folder! ")
)
)
页:
[1]