check data from different cells

S

Stefan - AW

Ok, new try.

I have to check data from different cells in different columns at the same
time in one “if†formula with several “if†conditions?
How can I compare them?
Ex:
A1=0 B1=12 D1=11 E1=0
A2=34 B2=56 D2=0 E2=0
A3=78 B3=0 D3=0 E3=22
A4=0 B4=0 D4=0 E4=0
Help with this would be greatly appreciated.
 
P

pomegranate-man

I have to check data from different cells in different columns at the
same time in one "if" formula with several "if" conditions?
How can I compare them?
Ex:
A1=0 B1=12 D1=11 E1=0
A2=34 B2=56 D2=0 E2=0
A3=78 B3=0 D3=0 E3=22
A4=0 B4=0 D4=0 E4=0

I'm not quite sure what's intended.

If the test is "one of the four sets of must hold," then maybe something
like this would work:
=OR(AND(A1=0,B1=12,D1=11,E1=0),
AND(A2=34,B2=56,D2=0,E2=0),
AND(A3=78,B3=0,D3=0,E3=22),
AND(A4=0,B4=0,D4=0,E4=0))

If the test is to identify which of the four are violated, then maybe this:
="Errors: "&
IF(AND(A1=0,B1=12,D1=11,E1=0),"","1 ")&
IF(AND(A2=34,B2=56,D2=0,E2=0),"","2 ")&
IF(AND(A3=78,B3=0,D3=0,E3=22),"","3 ")&
IF(AND(A4=0,B4=0,D4=0,E4=0) ,"","4 ")

Or maybe the test is something different.
 

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