CADEx

S::STARTUP

Short answer

A special LISP function name AutoCAD calls automatically after any drawing finishes loading.

(defun S::STARTUP () …) is a reserved function name. If AutoCAD finds a function called S::STARTUP defined when a drawing finishes loading, it calls it once with no arguments. This is the supported way to run per-drawing initialization code from acaddoc.lsp or an MNL file. If multiple LISP files each define S::STARTUP, only the last one loaded wins — the safe pattern is to append to S::STARTUP rather than redefine it.

Related terms

acaddoc.lsp

A LISP file AutoCAD loads every time a drawing is opened, used for per-document setup and (defun S::STARTUP).

AutoLISP

Autodesk's dialect of LISP, built into AutoCAD since 1986, used to write custom commands and automate drawings.