why doesn't excel count "numbers" in an IF formula

  • Thread starter Thread starter Noddy2011
  • Start date Start date
N

Noddy2011

My formula is =IF(AND(0<J3,J3<6),J3+1,"6") but when i use sum to add the
cells together is doesn't count any cell with "6" in. Why is this and how do
i change this please.
 
Hi,

The quotes around the 6 make it text so sum won't add them up

=IF(AND(J3>0,J3<6),J3+1,6)

Note I've also changed the formula to a more understandable format.

Mike
 
Hi,

I don't understand the question. You can't directly change a cell colour
with a formula but you can evaluate the formula result with conditional
formatting and change colour. What colours do you want and in what
circumstances?

Mike
 
Back
Top