Number rounding formula

  • 2
  • Question
  • Updated 3 months ago
I have setup a formula to calculate a 3 point estimate on tasks, obviously resulting in long decimal strings.  How do I round the result to 0 (or any other) number of decimals?  (By the way, I think I'm just missing something very obvious!)
Photo of Wilhelm

Wilhelm

  • 26 Posts
  • 0 Reply Likes

Posted 6 months ago

  • 2
Photo of Andrey Kazak

Andrey Kazak

  • 43 Posts
  • 4 Reply Likes
Try ROUND in hope that MM team added this function, but has not described this in help file.
Other option would be using VB script.
Photo of Wilhelm

Wilhelm

  • 26 Posts
  • 0 Reply Likes
Thanks, @Andrey - I've tried ROUND without luck.  Not sure how to apply VB script?
Photo of Andrey Kazak

Andrey Kazak

  • 43 Posts
  • 4 Reply Likes
The main strategy for VB script I see in tagging target cells, then loop thought target cells calculate 3-point estimate using standard VB functions (there is ROUND there) and write down the calculated value to estimate variable.
Does this make sense for you?
Photo of aHa!Coaching

aHa!Coaching, Champion

  • 1192 Posts
  • 116 Reply Likes
What is the Type of the property that's being used to store the value of the 3 point estimate?
Photo of Wilhelm

Wilhelm

  • 26 Posts
  • 0 Reply Likes
@mathieu, it's a number (of hours).
Photo of aHa!Coaching

aHa!Coaching, Champion

  • 1192 Posts
  • 116 Reply Likes
Try changing the Type to Integer, as in the screenshot below. It will round the number to 0 decimals.



Is this something you could use?
Photo of Wilhelm

Wilhelm

  • 26 Posts
  • 0 Reply Likes
Perfect solution to my problem!  Thanks @Mathieu!

It would still be great to have a round function for those times when I might need a number to say, 3 decimal places only, though.

Thanks for all the help!
Photo of Francisco

Francisco

  • 3 Posts
  • 3 Reply Likes
Hey, I think I just solved the issue.
You should define the field as Currency, then remove/delete the currency symbol and change the decimal places to whatever number of decimals you need.

Cheers!
(Edited)
Photo of Wilhelm

Wilhelm

  • 26 Posts
  • 0 Reply Likes
Great idea!  Thanks @Francisco!