problem creating string using <> to exclude

  • Thread starter Thread starter Julz
  • Start date Start date
J

Julz

good afternoon

have been using
=IF(OR(Z1=29302,Z1=28751),U1,"") to include cells w/ 29302 or 28751

thought this would work to exclude the same, but it's still including
them.
=IF(OR(Z1<>29302,Z1<>28751),U1,"")

please advise.

thanx,
~julz
 
I wrote too soon. I figured out what I was doing wrong.
=IF(OR(Z1<>29302)+(Z1<>28751),U1,"")
did the trick! :)
 
Don't know what your question is, really.

Anyway,

"=IF(OR(Z1<>29302,Z1<>28751),U1,"")"

Z1 will always be not equal to at least one of them, so the answer will
always be TRUE

Post again with an explanation of what you're trying to achieve

--

Kind Regards,

Niek Otten

Microsoft MVP - Excel
 
Hi!

You could try AND instead of OR. You want both of the two values to b
excluded so neither condition must be true.

Al
 

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

Back
Top