bigmaz 发表于 2022-7-6 08:57:00

Help: Start up lisp

Hi guys
 
I would like to have a lisp routine that will automatically load every time I open a drawing even when in the same session of Autocad.The command that I want it to do is to set the variable "LAYEREVAL" set to "1" when I open a drawing.How do I go about this?
 
Cheers

MSasu 发表于 2022-7-6 09:37:00

Please check this tutorial from LeeMac.
 
Regards,
Mircea

BlackBox 发表于 2022-7-6 10:02:23

 
 
Actually, the file the OP should use (if they have write-access) is ACADDOC.lsp - See this tutorial instead.
 
** Note - Only use Startup Suite if you do not have write-access to ACADDOC.lsp
 
ACADDOC.lsp is a user defined file, meaning that AutoCAD does not come with this file, but you can create one if it does not already exist, and AutoCAD will automagically load this file if found anywhere within your Support File Search Paths (SFSP). This code will do what you have requested economically:
 

(if (/= 1 (getvar 'layereval)) (setvar 'layereval 1))
 
HTH
页: [1]
查看完整版本: Help: Start up lisp