NISetVar

Related Topics Link IconRelated Topics

Definition

To be used in Windows scripts only:

This command has the following functionality:

  • Set values
  • Return values

Set values

The variable <NIVariable> gets the new value <external variable or value>.
(Both arguments are strings.)  If the variable does not exist yet it will be created (see example).

Return values

The command creates the return value TRUE if the value was returned correctly, if not FALSE.
To interpret this value you need to assign script variables (see example).

Command syntax for different Windows versions and script programming languages:

  • JScript
    You must enclose the arguments in brackets, as shown in the examples above.
  • VBScript
    You have to omit these brackets if you run VBScripts on Windows XP or higher.
    Reason: The Windows XP OS installs Windows Script Host (WSH) version 5.6. This version does not allow brackets in VBScripts.

Find more information on Windows Scripts in CallScript