Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search multiple workbooks for single range of info

Status
Not open for further replies.

vikingatc

Technical User
Jul 5, 2006
8
US
I'm trying to be able to generate a list of workbooks based on a range they contain called DateofChange. This is a simple date value. What I want to do is, from another workbook using VBA or VB proper in an independent program, to be able to "search" a number of workbooks and sort them based on the DateofChange. The hope is to be able to generate a list of files that have not been changed in some time so they can be reviewed/deleted, etc. I've tried a few things, but I'm pretty limited in my VBA knowledge - most of it is just within the Excel application itself. Any help would be appreciated.

Thanks from a new user

Ben
 
Hi Ben! This functionality is already built into Windows Explorer, so why go to all the hard work? Right click your start button and select Search. Click the "When was it modified" button and set appropriate date ranges. Then click the "More advanced options" dropdown and select files of type. Set this to "Microsoft Excel Worksheet."

Also, something similar exists for Excel:

Click File>Open>Tools>Search

Hope this helps...Tom

Live once die twice; live twice die once.
 
Or even just do a search on *.xls and then sort the results in 'date modified' order

Be aware that just because it hasn't changed doesn't mean it hasn't been used, so you might also want to pay attention to the 'Date accessed' field as well.

Regards
Ken............

----------------------------------------------------------------------------
[peace]It's easier to beg forgiveness than ask permission[2thumbsup]
----------------------------------------------------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top