Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

((CONVAROBJPUBPRIDAT))
   ROUND ( FloatConstant )

...

Returns: Nearest integer to original floating-point constant value.

...

ROUND can be used to round floating-point constants up or down to the nearest integer value. Note that this is for compile-time constant expressions only, not run-time variable expressions. For example:

Code Block
CON
  OneHalf   = 0.5
  Smaller   = 0.4999
  Rnd1      = round(OneHalf)
  Rnd2      = round(Smaller)
  Rnd3      = round(Smaller * 10.0) + 4 

...