Can you use the “Math.Round” function to round a number to the nearest 10?
For example, 694 should be rounded to 690. 695 to 700 and so on.
If so, how do you write it?
If “Math.Round” cannot be used for this, what else can be used?
Can you use the “Math.Round” function to round a number to the nearest 10?
For example, 694 should be rounded to 690. 695 to 700 and so on.
If so, how do you write it?
If “Math.Round” cannot be used for this, what else can be used?
Hi @Haltob01
kindly refer this thread
Hey @Haltob01
Welcome back to the UiPath Community.
Please try this simple solution:
Math.Round(your_no/10)*10
Just going to leave this here…
To retrieve the last place
Convert.ToDouble(System.Text.RegularExpressions.Regex.Match(doub_round.ToString,"\d(\.\d+)?(?=$)").Value)
RoundUpValues.xaml (5.6 KB)
Kind Regards,
Ashwin A.K