ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Zero Division (https://www.excelbanter.com/excel-programming/407509-zero-division.html)

Beep Beep

Zero Division
 
Can't remember the formula for not showing DIV/? error message when dividing
by zero

Chip Pearson

Zero Division
 
Something along the lines of

=IF(B1<0, A1/B1,"")

or

=IF(ISERR(A1/B1),"",A1/B1)

--
Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)



"Beep Beep" wrote in message
...
Can't remember the formula for not showing DIV/? error message when
dividing
by zero



Mike H[_3_]

Zero Division
 
On Mar 11, 5:18*pm, Beep Beep
wrote:
Can't remember the formula for not showing DIV/? error message when dividing
by zero


Hi,

You can have the catch all solution of

=if(iserror(your formula),"",your formula)
but this hides lots of errors so depending on your formula a better
solution may be to check for zero

=IF(A1=0,"",B1/A1)

which doesn't hide other errors

Mike


All times are GMT +1. The time now is 12:20 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com