Some OpusScript functions contain parameters that allow you to enter the name of a variable. The variable must contain the value you want to use in the parameter, for example |
var status = false |
The function Enable contains one parameter that can only be set to true or false. However, this function also allows you to insert a variable as the parameter – in this example, the variable is named status and contains the value false, therefore, the function Enable is set to false. |
Using variable names in parameters is useful because the value within the variable can always change. Using the example above, if we had entered button1.Enable(false) then button1’s enable feature is always false – by using a variable we can change button1’s enable feature to true or false at any time by changing the value of the variable. |