Rounding excel numbers

StefanoM

New Member
Joined
Jul 20, 2016
Messages
7
Dear All,
I have to display a rounded number in protected spreadsheet letting the user to dynamically select how may decimal places to put. It works quite well, except when I want a zero at the end of the number.
number to round A1 = 2.002345
decimal places B1 = 1
formula ROUND(A1, B1)
result of the formula = 2
But I want 2.0 to be displayed.

Thank you for your help,
Stefano
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
It works to display the number correctly, but the number is a text, so I cannot use it in further calculation I need (from example using the formula SUMIF).
 
Upvote 0
It works to display the number correctly, but the number is a text, so I cannot use it in further calculation I need (from example using the formula SUMIF).
Let's assume you have your rounded number in cell C1. You have two options:

1) Stick with the =TEXT(...) solution and use VALUE(C1) in your subsequent formulas.

2) Conditionally format cell C1 with a set of rules like this:
Rule =$B$1=1, custom number format 0.0
Rule =$B$1=2, custom number format 0.00
Rule =$B$1=3, custom number format 0.000 and so on.
 
Upvote 0

Forum statistics

Threads
1,214,653
Messages
6,120,750
Members
448,989
Latest member
mariah3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top