If Statement

  • Thread starter Thread starter Alex
  • Start date Start date
A

Alex

Hi In an If styatement, how would I go about testing to see if a cell
contained a text string please
- If (E2="*Phone","True","False"), which is what I assumed the syntax was,
doesm't work

Thanks
A
 
Alex said:
Hi In an If styatement, how would I go about testing to see if a cell
contained a text string please
- If (E2="*Phone","True","False"), which is what I assumed the syntax was,
doesm't work

One way:

=if(iserror(find("Phone",E2)), "false", "true")

Use SEARCH() if you want a case-insensitive match.
 
=ISNUMBER(SEARCH("phone",E2))

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 

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