6 Replies Latest reply: May 24, 2017 11:09 AM by John Worth

# How to round numbers.... using the num() function in a text object.

I'm working on a dashboard & I need to show CYTD Sales in a text object.   The formula I'm using is working but now I need to round the number down.   Currently I have \$69,181,750.6 I need to round this number to 69.2 MRoun

• ###### Re: How to round numbers.... using the num() function in a text object.

May be like this

=Round(69181750.6/1000000, 0.1)

• ###### Re: How to round numbers.... using the num() function in a text object.

Use Round() function.

round([CYTD Sales],100000)

after that yuo can divide by 1000000 to obtain 69.2MRoun

• ###### Re: How to round numbers.... using the num() function in a text object.

Michele,

Here's my current text , how would I incorporate your solution in the expression?

=num((sum({<year=,month=,quarter=,_CYTD_Flag={1}>} [# Amount])/1000000),'\$##.0') & ' M '

= 69.2 M

• ###### Re: How to round numbers.... using the num() function in a text object.

May be just this

=Num(Round(Sum({<year=,month=,quarter=,_CYTD_Flag={1}>} [# Amount])/1000000, 0.1), '\$#.0M')

or

=Num(Round(Sum({<year=,month=,quarter=,_CYTD_Flag={1}>} [# Amount])/1000000, 0.1), '\$#.0') & 'M'

• ###### Re: How to round numbers.... using the num() function in a text object.

Sunny,

Thanks both scripts worked like a charm.   Awesome!