Making a cell show blank until data is entered

G

Guest

I am trying to create a formula: =sum(a5,b5,d4). It is a continual
addition/subraction.
The next formula is =sum(a6,b6,d5) etc.
I am trying to make the cell that contains this formula to be blank when
both cells are blank.
I also use cell a5 or b5 for text and I want to be able to ignore the text
and not give an error. I dont always need to add cells a and b. Sometimes I
would only add A cell, sometimes only b cell and sometimes I would need to
add/subtract both
Any assistance is appreciated
 
B

Bernard Liengme

=IF(SUM(A6,B5,D4),SUM(A6,B5,D4),"")
or the equivalent, but longer
=IF(SUM(A6,B5,D4)>0,SUM(A6,B5,D4),"")
or if negative values and/or sum could be zero are possible
=IF(count(A6,B5,D4)>0,SUM(A6,B5,D4),"") will check that at least one cell
has a number

Note while SUM(A6,B5,D4) will correctly add up the numeric values in the
three cells, the formula =A6+B5+D4 will give a #VALE! error is any cell has
text (or other non-numeric value)

best wishes
 
G

Guest

=IF(COUNT(A4,B4)>0,SUM(A4,C2),"")
The above formula fixed the problem. Thank you for pointing me in the right
direction!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top