#startdefine
Declares the scope of precompiler constant declarations (#define's)
#startdefine
#define Constant {=
} Expression
<Your code here>
#enddefine
Description
Use the #startdefine/#enddefine directives to explicitly define the scope of precompiler constant declarations. This is especially useful if you want to define a precompiler constant that is only applicable in a specific script module, such as a trigger, operation, or entity.
It is possible to nest #startdefine/#enddefine blocks.
For more information, see Scope of Constants.
Example: Using #startdefine
In the following example:
- An outer #startdefine block
sets the scope the
DEF1
declaration to two operations,myOper01
andmyOper02
. - An inner #startdefine block
sets the scope of the
def2
declaration to themyOper02
operation.
;Script container #startdefine #define DEF1 = value1 operation myOper01 ... if (something = <DEF1>) ... endif end #startdefine #define DEF2 =value2 operation myOper02 ... if (something = <DEF2>) ... endif end #enddefine #enddefine
Version |
Change |
---|---|
10.2.01 |
Introduced |