Hiding the formula in Excel


Posted by David Snedeker on August 27, 2001 6:41 PM

I have designed a very simple spreadsheet that will tell me how many reservations to calls my reps have taken.

The formula is =SUM(C5/C4) and so on down the row. I am getting the message #DIV/0! which I know indicates that I am dividing by a divisor of 0 I think or something like that. I am fine with that. I just need to kow how to hide what that shows because I will be placing numbers in the 2 cells before it to properly let it divide. But in the meantime it will be 0. How do I hide #DIV/0!


Thanks
David

Posted by anno on August 27, 2001 7:56 PM

hi david
i think this will work:
=IF(C5,IF(C4,(SUM(C5/C4))),0)
also i may have missed something, but wouldn't it work just as well without the sum function, like this:
=IF(C5,IF(C4,(C5/C4)),0) )

Posted by Ian on August 28, 2001 3:39 AM

=IF(iserr(C5/C4) ,"",C5/C4)

Posted by Mark W. on August 28, 2001 6:59 AM

Even simplier...

You need only test the denominator as follows...

=IF(C4,C5/C4,"")



Posted by anno on August 28, 2001 4:13 PM

Re: Even simplier...

=IF(C4,C5/C4,"")

aha! took me a minute to see why your simplification works, but of course! - it's the denominator that causes the #div/0!. another valuable lesson. i bow before your knowledge, o excel addict.