Rounding
Rounding Up
Using Excel
Application.WorksheetFunction.RoundUp(value,0) - no decimal places
Rounding Down
Using Excel
Application.WorksheetFunction.RoundDown(value,-1) - no decimal places
The CINT Function
The CINT function returns the expression converted to an integer data type.
This function rounds up to the nearest integer if the fractional part is greater than 0.5.
This function rounds down if it is less than or equal to 0.5.
CInt(0.2) = 0
CInt(0.5) = 0
CInt(0.6) = 1
CInt(0.9) = 1
CInt(1.1) = 1
CInt(1.5) = 1
CInt(-1.1) = -2
CInt(-1.9) = -2
The INT Function
The INT function returns the integer portion of a number.
This function always rounds down to the nearest integer.
Int(0.2) = 0
Int(0.5) = 0
Int(0.6) = 0
Int(0.9) = 0
Int(1.1) = 1
Int(1.5) = 1
Int(-1.1) = -2
Int(-1.9) = -2
The FIX Function
The FIX function returns the integer portion of a number.
This function truncates without rounding.
Fix(0.2) '= 0
Fix(0.5) '= 0
Fix(0.6) '= 0
Fix(0.9) '= 0
Fix(1.1) '= 1
Fix(1.5) '= 1
Fix(-1.1) '= -1
Fix(-1.9) '= -1
The ROUND Function
The ROUND function rounds numbers to a given number of decimal places.
Round(0.2, 0) '= 0
Round(0.5, 0) '= 0
Round(0.6, 0) '= 1
Round(0.9, 0) '= 1
Round(1.1, 0) '= 1
Round(1.5, 0) '= 2
Round(-1.1, 0) '= -1
Round(-1.9, 0) '= -2
© 2025 Better Solutions Limited. All Rights Reserved. © 2025 Better Solutions Limited TopPrevNext