Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
find multiple or by different words
Hello,
I would like to us the find function on a sheet to search for either of 2 words. If I want to search for multiple words for example A and B I use: ..Find(what:="A" & "*" & "B", But what do I use if i want to search for A OR B. I know I can first search for A and subsequently for B but I would like to use a single find function. thanks in advance! Lucas van Rijsewijk Deurne, The Netherlands |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
find multiple or by different words
Hello Lucas
I don't think you can search for two strings at once. Maybe this will help you. Set found = Columns("A").Find(what:="A") If found Is Nothing Then Set found = Columns("A").Find(what:="B") End If Regards, Per Copenhagen, Denmark "Lucas" skrev i meddelelsen ... Hello, I would like to us the find function on a sheet to search for either of 2 words. If I want to search for multiple words for example A and B I use: .Find(what:="A" & "*" & "B", But what do I use if i want to search for A OR B. I know I can first search for A and subsequently for B but I would like to use a single find function. thanks in advance! Lucas van Rijsewijk Deurne, The Netherlands |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
find multiple or by different words
Thanks for your reply Per!
Using the Set function also avoids an error message if nothing is found. Thanks for helping out this newbie! |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
find multiple or by different words
Hi Lucas
Thanks for your reply. I'm glad to help. Best regards, Per "Lucas" skrev i meddelelsen ... Thanks for your reply Per! Using the Set function also avoids an error message if nothing is found. Thanks for helping out this newbie! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Find multiple words in cell? | Excel Discussion (Misc queries) | |||
How can I find all possible combinations of words? | Excel Worksheet Functions | |||
FIND-COPY DIFFERENT WORDS WITH MACRO | Excel Discussion (Misc queries) | |||
Find & Replace Whole Words | Excel Programming | |||
Need to find the 1st two characters of the 1st two words | Excel Worksheet Functions |