I have numbers in cells in Excel. I want the numbers formatted so that if they have decimal places they show to a maximum of two, and if they have no decimal places it doesn't show any.
For example:
• 1 should be formatted as 1 NOT 1.00
• 0.75 should be formatted as .75
• 0.2 should be formatted as .2
• 0 should be formatted as 0
The closest custom format code I've come up with is 0.##. Unfortunately this formats 1.00 as 1. (note the extra decimal point).
How can I create a custom format code to remove the decimal point on cell values the report a full whole number?

