System variables are settings that control how certain commands work.
Whereas commands usually initiate an activity or open a dialog box, system variables control the behaviors of commands, default values for operations, or the appearance of the user interface. They turn on or turn off modes such as Snap, Grid, or Ortho. They set default scales for hatch patterns. They store information about the current drawing or program configuration. You can use a system variable to change a setting or to display the current status. Many system variable settings can also be modified in a dialog box or on the ribbon.
Some system variables are controlled using bitcodes. With these system variables, you add values to specify a unique combination of behaviors. For example, the LOCKUI system variable provides the following bitcode values:
0 | Toolbars and windows not locked |
1 | Docked toolbars locked |
2 | Docked or anchored windows locked |
4 | Floating toolbars locked |
8 | Floating windows locked |
Thus, if LOCKUI is set to 5 ( that is, 1 + 4 = 5), only docked and floating toolbars are locked. Docked, anchored, and floating windows are not locked.
The SETVAR command lists all the system variables in the text window or the extended prompt history. You can use an asterisk (*) as a wildcard to filter the list.