Thread: Divided by zero
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 6,953
Default Divided by zero

=if(iserror(a1/b1),0,a1/b1)

or

=if(b1=0,0,a1/b1)

--
Regards,
Tom Ogilvy


"Hassan" wrote:

Hi All,

I have two cells e.g. a1 & b1 and c1 contains the formula =a1/b1, if b1
equals to 0 then i need that formula returns 0 in c1 instead of #DIV/0!

Plz help

Regards

Hassan