The vgLib.compareNum() system function compares the contents of two numeric variables of the same type and determines whether the first is less than, equal to, or greater than the second.
vgLib.compareNum() is one of a number of functions maintained for compatibility with code migrated from VisualAge® Generator. New code can use standard EGL operators for these purposes.
vgLib.compareNum(
var1 NumType in,
var2 NumType in)
returns (result NumType)
The following example illustrates the vgLib.compareNum() function:
myVar01, myVar02, result INT;
myVar01 = 4;
myVar02 = 7;
result = vgLib.compareNum(myVar01,myVar02); // result = -1