LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
MDW MDW is offline
external usenet poster
 
Posts: 117
Default Search for multiple things at once

I'm trying to do a search to determine if any cells contain references to
other worksheets in the same workbook. For instance, if I've got a worksheet
named "Daily" and another worksheet named "YTD", I may have a function like
this:

=MAX(Daily!A2:A999)

I want to identify that cell as referring to another worksheet.

I have a search feature that currently looks for linked worksheets according
to one of three strings (strSearch is a String variable containing the name
of the worksheet I'm searching for):

strSearch & "'"
strSearch & "!"
strSearch & ","

I can't use wildcards (strSearch & "*") because I have other cells that link
to entirely different WORKBOOKS, that may have the word "Daily" as part of
the path (does that make sense)?

Right now I'm executing three different searches, as shown above.

Set objFind = objWorksheet.Find(strSearch & "'", LookIn:=xlFormulas).
etc.

Is there a way I can combine these three parameters into one search?
Something like strSearch & "'" OR strSearch & "!" OR strSearch & ","


I hope this makes sense. TIA.


--
Hmm...they have the Internet on COMPUTERS now!
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
one code to do multiple things Morgan New Users to Excel 0 February 24th 10 07:09 AM
multiple results from search / how to? ORLANDO V[_2_] Excel Discussion (Misc queries) 2 January 30th 08 03:10 PM
multiple search Neska Excel Worksheet Functions 3 April 17th 07 12:34 AM
Search using multiple worksheet gloss Excel Worksheet Functions 5 May 10th 06 02:34 AM
How do I search excel spreadsheets using multiple search criteria. Kasper Excel Worksheet Functions 4 December 15th 05 12:26 AM


All times are GMT +1. The time now is 02:15 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"