Semantic Auditing of DCL Files
 
 
 

AutoCAD provides a choice of four levels (0-3) of semantic auditing for DCL files (see the following table). Auditing attempts to detect code in the DCL file that is likely to be problematic or unnecessary. These audits are done at DCL load time. To set the audit level for a DCL file, include a line such as the following anywhere within the DCL file, but not inside any tile definitions:

dcl_settings : default_dcl_settings { audit_level = 3; }

If your DCL file references other DCL files with include directives, you should define dcl_settings in only one file. The defined audit level is used in all included files. The following table describes each audit level:

Semantic auditing levels

Level

Description

0

No checking. Use only if the DCL files have been audited and have not been touched since the audit.

1

Errors. Finds DCL bugs that may cause AutoCAD to terminate. This level of checking is the default and involves almost no delay. Errors can include using undefined tiles and circular prototype definitions.

2

Warnings. Finds DCL bugs that result in dialog boxes with undesired layout or behavior. A modified DCL file should be audited at this level at least once. The warning level catches mistakes such as missing required attributes and inappropriate attribute values.

3

Hints. Finds redundant attribute definitions.

To get the most out of the auditing facility, you should keep the audit_level at 3 during program development. Remember to strip out the dcl_settings line before shipping DCL files to users.