View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Dave Peterson
 
Posts: n/a
Default Text "comparison" operator for "contains" used in an "IF" Function

=find() is case sensitive
=search() doesn't care about case (Example/EXAMPLE/ExAmPlE will be treated the
same)

another way:

=if(countif(a1,"*example*")0,"yep","nope")

(not case sensitive)

Pawaso wrote:

I'm trying to use an "IF" function to look for a certain word in a string of
text. Is there a "contains" operator for this?

I tried using =if(A1="*example*","yes","no") but this does not seem to work.


--

Dave Peterson