View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Barb Reinhardt Barb Reinhardt is offline
external usenet poster
 
Posts: 3,355
Default Search All Files Find Newest One Report To Excel 2007

You can browse for a folder using the code here

http://www.cpearson.com/excel/BrowseFolder.aspx

You should be able to glean the date using something here

http://www.exceltip.com/st/List_file...Excel/446.html

I think I'd look at FileItem.DateLastModified for the date and FileItem.Name
for the name
--
HTH,
Barb Reinhardt



"Stever" wrote:

Hello All

I am running Excel 2007 I need to create a VBA script that will allow me to
select a folder(Team) then the program would walk the tree and find the
newest file based on date modified in each folder(Project) (Must search sub
folders of each project as well) The goal here is to provide each team with
a list of their project and the latest activity on each project to help them
decide which projects are ready to be archived off our main server.

Team
Project1
Project2
Project 3

Return would look like

Team Project Newest File
Harry Stadium 10/17/2005
Harry Theater 11/25/2006

I'm looking for some Code ideas as well as concepts. I've never been very
good at creating efficient algorithms / searches. Each Project may have 10k
files.

If doing this in Excel 2003 is easier I can do that as well.

Thanks

Steve