My formula in B3 is =A3+B2-B1. I want B3 to be blank if both B2 and B1 are blank also. Could anyone help me with this please?
2 Answers
To start out, first lets work with one cell. B1.
=IF(B1="","",SUM(A3+B2-B1))
This will return blank if B1 is empty or will do the sum. Now we can just wrap that in another if.
=IF(B2="","",IF(B1="","",SUM(A3+B2-B1)))
The problem with ISBLANK
is that if there is a formula in that field, it will not return blank, even if there is no number in the field.
-
Good point about the
ISBLANK
function. However, no need for theSUM
, and I thinkAND
is more simple then a nestedIF
especially when wanting to check for more then 2 conditions. So I would do:=IF(AND(B2="",B1=""),"",A3+B2-B1)
.– User15Aug 26, 2015 at 17:38