Can I use "*xyz" in a formula

M

mgerken79

Can I use "*" in a formula to search for a character or string of text
characters entered into a cell?

I have text, sometimes even a sentence, in a cell. I want to use an if() to
look in that cell, look for a character or string of text characters, then
return "Yes" if it finds them or "No" if it doesn't. Can excel functions use
the "*" like other searches?

Thanks for you help.
 
P

Pete_UK

Some functions can, and others can't. You may want to look up the
SEARCH function in XL Help, or COUNTIF, eg:

=IF(COUNTIF(A1:A10,"*x*")>0,do_something,do_something_else)

is looking for the character x in any of the cells in A1:A10.

Hope this helps.

Pete
 

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