I have a problem in match function

Closed
Report
-
 Blocked Profile -
Hello,
i want to ask u that if i have a text in one cell and i want to match more than one text from cell.for ex. cell contains(buy now this is a spam mail.offer now..it contains spam words) and i want to match either spam, or buy or now. So plzz help me how can i match these words in a single line.

1 reply

I think this is a wire frame for what you are asking.

You will have to set the range to whatever row you wish to check.

dim therange as Range
therange = Worksheets(1).Range("A1:A10")
=if(or(therange="spam",therange="buy",therange="now"),True,False)


That is one way!

Note: not tested as written

It's kind of fun to do the impossible! -Walter Elias Disney
0