VLOOKUP "Contains text"

  • Thread starter Thread starter Stephen
  • Start date Start date
S

Stephen

Hi All,

How can I get VLOOKUP to find a particular word within a line of text.

For example A1= "Peter, Mark, Stephen" and B1="10". How can I ge
VLOOKUP to look for "Mark" and result in "10"?

Please help.

Stephe
 
This formula works assuming no spaces in A1 and lookup table named rang
"MyLookup". It works by finding the 2 commas and taking whatever i
between.

=VLOOKUP(MID(A1,FIND(",",A1,1)+1,FIND(",",A1,FIND(",",A1,1)+1)-FIND(",",A1,1)-1),MyLookup,B1,FALSE
 
Not quite sure what your asking to do here,
but here is a direction to perhaps take,
modify to suit your needs.

=IF(FIND("Mark",A1),B1,"") ' If(True,do something, otherwiseshowblank)
 

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