TRUNC Function [Visio 2003 SDK Documentation]

Returns a number truncated to numberofdigits.

TRUNC(number,numberofdigits)

Remarks

If numberofdigits is greater than 0, number is truncated to numberofdigits to the right of the decimal. If numberofdigits is 0, number is truncated to an integer. If numberofdigits is less than 0, number is truncated to numberofdigits to the left of the decimal.

Example 1

TRUNC(123.654,2)

Returns 123.65.

Example 2

TRUNC(123.654,0)

Returns 123.

Example 3

TRUNC(123.654,-1)

Returns 120.