0
votes

I am trying to use Conditional Formatting to turn cells red if the sum of other correlating cells is not equal to what is in that cell. However, I want to ignore the blank cells and cells with a hyphen in them (-). I've been able to ignore blank cells using:

=IF(COUNTBLANK(A1:C1),,SUM(A1:C1))

However, I can't figure out how to get it to ignore cells with "-" in them too. Example of what I'm doing:

Sum of A1:C1 = 6

If D1 is NOT 6, then the cell will be red.

How do I get the formula to ignore the "-" cells in all A1:D1?

1

1 Answers

0
votes

Clear any existing CF formatting from ColumnD, select ColumnD and apply a CF formula rule of:

=and(sum(A1:C1)<>D1,D1<>"",D1<>"-")

with red fill.