2011

Table Of Contents
version of LAYER command that displays command prompts rather than the
palette version. The result is equivalent to entering -layer at the command
prompt. The fourth line is blank, ending LAYER.
You could run a script at startup to open a drawing by using the following
syntax in the Terminal:
AutoCAD drawing_name -b setup
All file names that contain embedded spaces must be enclosed in double
quotes, for example, “guest house”.
Including the file extensions .exe, .dwg, .dwt, and .scr is optional. If AutoCAD
for Mac cannot find the script file, AutoCAD for Mac reports that it cannot
open the file.
To run the same script at startup but create a new drawing using the
MyTemplate.dwt file as the template, enter the following in the Terminal:
AutoCAD -t MyTemplate -b setup
This command creates a new drawing and issues a sequence of setup commands
from the setup.scr file. When the script has finished running, the command
prompt is displayed.
If you want to use the default template for the new drawing, you can omit
the -t switch and the template file name.
To run a script at startup
1 Click local drive Applications Utilities Terminal.
2 In the Terminal, enter AutoCAD drawing_name
-b script_name.
NOTE AutoCAD listed above is the path to the AutoCAD executable. By
default it is located at:
/Applications/Autodesk/<release>/AutoCAD.app/Contents/MacOS/AutoCAD
To start a new file, instead of a drawing file name, enter the -t switch and
the name of a template file: -t template_drawing.
The name of the script file must be the last parameter listed. The file
extensions are optional.
3 Press Enter.
AutoCAD for Mac opens the drawing and executes the commands in the
script file. When the script has been completed, the Command prompt
is displayed.
92 | Chapter 6 Command Scripts