It is important to understand the difference between the two methods of assigning values to variables:
| • | The $var_def command essentially defines the initial value of a variable. With the exception of a few special names, a value specified which contains other variable references is never evaluated to expand these variables. |
| • | The $set_var command dynamically assigns a new value to a variable. A value specified which contains other variable references is always evaluated to expand these variables. |
The $var_def command can be used in the configuration file (CFG), the user profile (USR) or user properties (UJP) file, an FS file, or an MCF file:
| $var_def [CFG] | These variables are permanently defined and never change. However a later assignment to a variable of the same name takes precedence and can therefore override the value for the duration of a single call. |
| $var_def [USR, UJP] | These variables are established at the start of each call. However an assignment to a variable of the same name during the call takes precedence and can therefore override the value for the duration of call. They do not survive the end of the call. |
| $var_def [FS] | These variables are established at the start of the outbound call originated by their FS file and are available for that call only. |
| $var_def [MCF] | These variables are set by the system to record the variables in effect at the time of processing a received fax. These values either originate in the user profile controlling the call or may be established in a post-receive process of type infobox. When assigning a variable in the USR which is to be replicated in the MCF, you would usually use a double @ sign as shown in the examples. |
The $set_var command can only be used in an Infobox file (IIF):
| $set_var [IIF] | These variables are set or created in infobox logic. They survive only until the end of the call. A value assigned to a variable with the same name as one defined earlier in a $var_def overrides the defined value for the duration of the current call only. Assignments to some special variable names have side-effects other than changing the value of the variable: for example an assignment of a filename to the 'variable' named DeleteThisFile actually causes the named file to be deleted. |
Topic url:
http://www.copia.com/support/refmanual/index.html?var_def_vs__set_var.htm