IF formula won't work!

fidgen

New Member
Joined
Aug 20, 2002
Messages
46
what is wrong with this? I've switched brackets around and done all sorts, but I'm banging my head now!

=IF((AVERAGE(DataRev!B2:B32))=0,#N/A,IF(Movements!$D2)=0,#N/A,(AVERAGE(DataRev!B2:B32))*Movements!$D2)

I bet its something so **** simple!
:)

cheers
Hugh
 

Excel Facts

Excel motto
Not everything I do at work revolves around Excel. Only the fun parts.
To fix
remove the close bracket from (movements!$d2)=0
to say ,if(movements!$d2=0,..........
hope this works for you

stuart
 
Upvote 0
On 2002-09-20 03:12, fidgen wrote:
what is wrong with this? I've switched brackets around and done all sorts, but I'm banging my head now!

=IF((AVERAGE(DataRev!B2:B32))=0,#N/A,IF(Movements!$D2)=0,#N/A,(AVERAGE(DataRev!B2:B32))*Movements!$D2)

I bet its something so **** simple!
:)

cheers
Hugh

=IF((AVERAGE(DataRev!B2:B32))=0,#N/A,IF(Movements!$D2)=0,#N/A,(AVERAGE(DataRev!B2:B32))*Movements!$D2)

Why not simply...

=AVERAGE(DataRev!B2:B32)*Movements!$D2

which would give either a non-zero or zero result?

If you rather see #N/A as result when one of the terms is 0, then

=IF(SETV(AVERAGE(DataRev!B2:B32)*Movements!$D2),GETV(),#N/A)

would be an attractive option. SETV and GETV are part of the add-in morefunc.xll, downloadable from:

http://longre.free.fr/english/index.html
 
Upvote 0

Forum statistics

Threads
1,217,356
Messages
6,136,078
Members
449,988
Latest member
Mabbas

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top