SetVariable ( <$variable>,<value>
)
Changes the scope of the variable from local to global and assigns value to all instances of the variable.
Parameters
<$variable> The
variable for which the value has to be assigned.
<value>
The value to assign.
Remarks
- After declaration, you can access
the value of anywhere from the script, using the variable <$variable>.
- Useful in creating a variable and assigning values from inside a function.
Example
SetVariable("$Acno",$AcNum)
- Here, the scope
of $AcNum is inside a function. Setting the value of $AcNum to $Acno will
make $Acno accessible from anywhere inside the script.