View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
[email protected] samer.kurdi@gmail.com is offline
external usenet poster
 
Posts: 14
Default Find text in a string that matches value(s) in a range

I have a list of codes that look like this:

cjm-dtm_6a184
342_cjm-fmu323_engine
etc.

I would like a simple formula that would check to see if a string, in
this case "cjm-" exists in the code. Fairly easy to do using the "find"
function, but I'm running into the following problem:

My list of strings-to-look-for has grown such that I am unable to nest
enough "IF" statements within the function to check for all of them.

Does anybody know of the best way to write a macro that would check if
a cell value includes values from a range? Ideally the output would be
the first string found from the left side of the code.

Thanks