FUNCTION: Fix( )
Implemented in version 1.0
function converts a decimal number (floating-point) to an integer number (fix-point).
There is a companion function
that also converts to integers. There is one major difference between
rounds negative numbers down.
rounds negative numbers up.
<% =Fix(123.456) %>
Positive numbers are not rounded up. The decimal point and all digits to the right are effectively chopped off.
<% =Fix(123.899) %>
Negative numbers can also be converted. Negative numbers are rounded up (towards more positive). The decimal point and all digits to the right are effectively chopped off.
<% =Fix(-123.899) %>
Copyright 1999-2004 by Infinite Software Solutions, Inc. All rights reserved.