Add

Item Description

Use with:

Startup scripts, Terminal Launcher, Web, Windows

SecureLogin Version:

3.0

Type:

Variable manipulator

Usage:

Add Variable1 Variable2 [?Result]

Arguments:

Variable1






Variable2

[?Result]

The first argument, the number that the second argument will be added to. If the optional ?result argument is not passed in, this argument also contains the result of the addition equation. If you use Variable1 without the ?Result argument, Variable1 must be a SecureLogin variable. Otherwise, Variable1 can be any numeric value.

The second argument, the number added to the first argument in the equation. Variable2 can be a SecureLogin variable or a numeric value.

Optional. The sum or result of the equation.

Description:

Adds one whole number to another. (Doesn't add fractions.) The numbers can be hard-coded into the script, or they can be variables. The result can be output to another variable or to one of the original numbers.

Syntax Examples:

Add 1 2 ?Result 
Add ?LoginAttempts ?LoginFailures
Add ?LoginAttempts ?LoginFailures ?Result
Add ?LoginAttempts 3
Add ?LoginAttempts 3 ?Result

Example
Windows Script:

The values of Control IDs 103 and 104 are read into variables. From there they are added, and the result is typed into Control ID 1. From there, they are added, and the result is typed into control ID 1.

ReadText #103 ?Number1 
ReadText #104 ?Number2
Add ?Number1 ?Number2 ?Result
Type ?Result #1