Variable Usage

The configuration file is optional, as are all of its contents. For this reason, no errors in the configuration file are ever reported. The -l runtime option can help debug configuration file problems.

In the descriptions of some runtime configuration variables, you will find comments about behavior under the Windows environment; unless otherwise noted, these comments apply to all 32-bit versions of the Windows operating system.

Runtime configuration variables may be placed in either the runtime configuration file or the machine's environment. When they are placed in the runtime configuration file, upper- and lower-case names are equivalent, as are hyphens and underscores. When placed in the machine's environment, the keywords must be all upper case and must use underscores instead of hyphens. See Runtime Configuration in the ACUCOBOL-GT User’s Guide for more details about the configuration process.

All configuration variables that have a default value are used by and affect the runtime system in the same way that they would if they were in the configuration file. That is to say, a configuration variable that has a default value is treated as if it appears in the configuration file set to the default value.

The values of many runtime configuration variables may be changed at run time with the SET ENVIRONMENT verb. The syntax is:

SET ENVIRONMENT env-name TO env-value

env-name may specify either the literal name of the variable or a data-item whose value is the name of the variable. If you specify the actual name of the variable, such as CODE_CASE, you must enclose the name in quotes. env-value is the value to which env-name will be set. If it is a numeric data item, it is treated as if it were redefined as an alphanumeric data item.

Most configuration variables can be read with the ACCEPT FROM ENVIRONMENT statement. If the variable to be read is numeric, the receiving field must be defined either as a numeric field or as an alphanumeric field of five or more characters. If it is defined as alphanumeric and is longer than five characters, the value that is read from the environment will occupy the leftmost five characters of the field and the remainder will be space-filled.