Script functions reference > Script functions in alphabetical order > A > Abs

Abs
Syntax
Abs(num);
Description
Returns the absolute value of a number.
Returns
The absolute value of the num argument.
Example
The following example illustrates the use of the Abs function.
$c = Abs(Num($a) - Num($b));
In this example, the num argument is a subtraction of Num($b) from Num($a). If $b is 40 and $a is 20, then $c will be the absolute value of -20, i.e. 20.
OpenText StreamServe 5.6 Updated: 2013-03-01