View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Gmaz Gmaz is offline
external usenet poster
 
Posts: 2
Default Help with formula (IF)

I have simple task to calculate % between two numbers:

A B %
1 2 +50%
2 1 -50%
1 1 0%

No problem until I dont get 0 as value in columns. Now I have found solution
to solve if A is 0, or if B is 0, but what to do if both values are 0,
because I got error sign and my table must be "clean".

=IF(B11=0;"-100%";IF(A11=0;"100%";(B11/A11)/B11))

This is what I have on right now but for both values 0 I get -100% instead
of 0.

Thank you in advance.