How to rndup and rnddown in uipath

I need to rndup and rnddown the value in uipath
Eg:22.34=22 for rnddown
22.56=23 for rndup

@sruthesanju

image

Math.Floor(22.56)
Math.Ceiling(22.56)

Hello,

Round down - Math.Floor
Round up - Math.Ceiling
Round - Math.Round

e.g. Math.Floor(2.6) = 2; Math.Ceiling(2.6) = 3; Math.Round(2.6) = 3

1 Like

Hi,

FYI, if you want to round off, the following will work.

Math.Round(22.34, MidpointRounding.AwayFromZero)

Math.Round(22.56, MidpointRounding.AwayFromZero)

Regards,

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.