Help with IF statement check value in multiple cells

C

CH53

I am trying to use an if statement that checks for a value across multiple
cells and I can't seem to get it to work. I am not sure if I am supposed to
use the COUNT or not.

As an example I have 5 cells

c1
c2
c3
c4
c5
And the value in these cells is either going to be Yes or No

Then I have cell
d1
This cell will have a value that is a number

I need to use the above data in 2 different ways - one and IF(AND and one in
and IF(Or

I came up with the following ideas but neither seem to work:

if(and(c1:c5="Yes",d1<1),"Good",If....(checks some other things)

If(or(c1:c5="No",d1<1),"Bad", If......(checks some other things)

OR
If(and(c1="yes",c2="yes",c3="yes",c4="yes",c5="yes",d1<1),"Good", If.....

If(or(c1="no",c2="no"c3="no",c4="no",c5="no",and(d1<1)),"Bad", if.....

Thanks in advance for your help.
 
D

Dave Peterson

I'm not sure how many checks you're going to apply, but maybe:

=if(countif(c1:c5,"yes")=5,"all Yes","not all yes")
=if(countif(c1:c5,"yes")=0,"all non-yes","at least one yes")

Add that D1<1 in where you like:

=if(and(d1<1,countif(...)),....
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top