How to assign a default value

J

J.Harmon

I am trying to create an estimate sheet for my service shop, I have formulas
that add totals, however I have other formuals that multiply the quantity of
a part by the price. when I don't uses those lines I have to go through and
enter a zero in everythime to correct the formula error. is ther anyway to
set that when there is nothing in the cell it automatically goes to a value
of zero?
 
J

J.Harmon

I tried to use a if function, but the only problem is that if I enter a
number and then delete it due to a mistake or something then it doesn't go
back to a zero value.
 
J

JE McGimpsey

The I suspect you're "deleting" your value by pressing the spacebar
instead of Delete. That inputs a space character, which XL sees as a
value rather than blank.

You could use

=IF(LEN(TRIM(A1))=0,0,A1*B1)

instead...
 
Top