IF statement with strings

  • Thread starter Thread starter stuart
  • Start date Start date
S

stuart

I have a column of cells each containing two words (i.e.
blue sky, cold water, red apple etc) and want the next
column to contain a True/False answer if a logical
statement says "if a cell contains the words red or blue
set to true else set to false". The cloeset I've got is:

=IF(OR(A1:A7="red",A1:A7="blue"),TRUE)

but I need a wildcard because of the two words in a cell,
but that just sets all to False.

However, in the complete spreadsheet there are more than
30 cells with the two word strings.

Thanks.
 
=OR(ISNUMBER(FIND("Red",A1)),ISNUMBER(FIND("Blue",A1)))

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
Back
Top