Forum Discussion
Ranjit1960
Aug 04, 2022Copper Contributor
Conditional formatting for decimals
Hello Experts, I am creating an excel sheet where user will have to put values with 4 decimal places. The value will turn red if it does not have four decimal places (i.e. more or less decimals p...
arnel_gp
Aug 04, 2022Iron Contributor
you can use this condition, where A1 is the start of the range to format:
=AND(ISERROR(LEN(A1)-FIND(".",A1))=FALSE, LEN(A1)-FIND(".",A1)<>4)
=AND(ISERROR(LEN(A1)-FIND(".",A1))=FALSE, LEN(A1)-FIND(".",A1)<>4)
- Ranjit1960Aug 05, 2022Copper Contributorarnel_gp
Thanks for the formula! This is still not giving me the required result. Now I started getting the values with all the decimals turning black.
I want just the four decimals values turning black, even if the fourth decimal is zero.- arnel_gpAug 06, 2022Iron Contributori don't think it would be possible with Trailing 0, since Excel automatically remove them if the the cell is not formatted as Text.