formula to see if cell contains one of two text values

B

brian.h.coleman

I am interested in writing a formula that will check to
see if a cell contains one of two words, and then will
return a value.

So, for example:

=IF(ISNUMBER("textA" or "textB"),"yes","no")

I know this formula isnt exactly correct. Can you help?
 
F

Frank Kabel

Hi
one way:
=IF(OR(COUNTIF(A1,{"*textA*","*textB*"})),"yes","no")

--
Regards
Frank Kabel
Frankfurt, Germany

"(e-mail address removed)"
 
T

Trevor Shuttleworth

Brian

if you wanted to test cell A1, use:

=IF(OR(A1="textA", A1="textB"),"yes","no")

Regards

Trevor
 

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