fbpx

Method Common.GenerateRandomNumber

Returns a non-negative random integer

Usage

Function ZAP.Common.GenerateRandomNumber ( 
    Integer MinValue [Optional],
    Integer MaxValue [Optional]
)

Parameters

MinValue (optional)

Type: Integer

Default value: 0

The inclusive lower bound of the random number returned

MaxValue (optional)

Type: Integer

Default value: 1000

The exclusive upper bound of the random number returned. MaxValue must be greater than or equal to MinValue.

Returns

Random number

Example

VBScript

msgbox Zap.Common.GenerateRandomNumber(10, 100)

JavaScript

alert(Zap.Common.GenerateRandomNumber(10, 100));

Documentation Categories

ZAPTEST

FARM

LOAD