Local

Item Description

Use with:

All

SecureLogin Version:

3.0

Type:

Variable manipulator

Usage:

Local ?Variable

Arguments:

?Variable

The runtime variable that will be declared as local.

Description:

Declares that a runtime variable will only exist for the lifetime of the script. Use local runtime variables the same way as normal runtime variables, and still write local runtime variables as ?Variable.

Declare local runtime variables to be local by using the Local command, followed by the variable name. When runtime variables are declared local, they cannot be set back again. You can declare a runtime variable to be local at any time in a script.

Using local runtime variables slightly increases the performance of SecureLogin. Use local runtime variables to run scripts multiple times and not have the runtime variables stored between each run of the script.

Also use local runtime variables to prevent runtime variables from overwriting each other. Overwriting could happen if two instances of a script are running at the same time. For example, use the Local command if two instances of Terminal Launcher are running, each instance running the same script but attached to different emulator sessions.

Example:
Windows Script
A variable is declared local, then used to count the number of times a dialog box has been displayed. If the box has been displayed too many times, SecureLogin alerts the user, then closes the application.

# Invalid Login Message 
Dialog
Class #32770
Title "Login Failure"
EndDialog
Local ?RunCount 
Increment ?RunCount
If ?RunCount Gt "5"
MessageBox "Closing Application"
KillApp "PasswordText.exe"
EndIf
Type $Username
Type $Password