Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default SubFolders in macro


Hi Guys,
I need some code that will allow me to search a folder "Model1", an
it's subfolders "Vend1, Vend2, Vend3" etc. for the file "Risk Filte
VENDCODE latest.xls", open the file, copy some cells of the "Summary
sheet onto a master sheet, and then close the file and move on to th
next Risk filter file, which will be a different subfolder. I
possible, it would then move on to the next master folder "Model2".
can just run that as a different sub if needs be though...
I don't need to record the VENDCODE results or anything so a wildcar
there is fine, it's the subfolder searching that's getting me stuck.
can do all the workbook specific code... if anyone could supply th
looping subfolder searching bit, that would be excellent.

Thank you,

Garet

--
pianoma
-----------------------------------------------------------------------
pianoman's Profile: http://www.excelforum.com/member.php...fo&userid=3371
View this thread: http://www.excelforum.com/showthread.php?threadid=53713

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default SubFolders in macro

http://support.microsoft.com/kb/185476/EN-US/
How To Search Directories to Find or List Files

http://support.microsoft.com/kb/185601/EN-US/
HOW TO: Recursively Search Directories by Using FileSystemObject

http://support.microsoft.com/kb/186118/EN-US/
How To Use FileSystemObject with Visual Basic

--
Regards,
Tom Ogilvy


"pianoman" wrote:


Hi Guys,
I need some code that will allow me to search a folder "Model1", and
it's subfolders "Vend1, Vend2, Vend3" etc. for the file "Risk Filter
VENDCODE latest.xls", open the file, copy some cells of the "Summary"
sheet onto a master sheet, and then close the file and move on to the
next Risk filter file, which will be a different subfolder. If
possible, it would then move on to the next master folder "Model2". I
can just run that as a different sub if needs be though...
I don't need to record the VENDCODE results or anything so a wildcard
there is fine, it's the subfolder searching that's getting me stuck. I
can do all the workbook specific code... if anyone could supply the
looping subfolder searching bit, that would be excellent.

Thank you,

Gareth


--
pianoman
------------------------------------------------------------------------
pianoman's Profile: http://www.excelforum.com/member.php...o&userid=33712
View this thread: http://www.excelforum.com/showthread...hreadid=537137


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default SubFolders in macro


Thanks Tom... you're a wealth of useful info!

Ta,

Tom Ogilvy Wrote:
http://support.microsoft.com/kb/185476/EN-US/
How To Search Directories to Find or List Files

http://support.microsoft.com/kb/185601/EN-US/
HOW TO: Recursively Search Directories by Using FileSystemObject

http://support.microsoft.com/kb/186118/EN-US/
How To Use FileSystemObject with Visual Basic

--
Regards,
Tom Ogilvy


"pianoman" wrote:


Hi Guys,
I need some code that will allow me to search a folder "Model1", and
it's subfolders "Vend1, Vend2, Vend3" etc. for the file "Risk Filter
VENDCODE latest.xls", open the file, copy some cells of the

"Summary"
sheet onto a master sheet, and then close the file and move on to

the
next Risk filter file, which will be a different subfolder. If
possible, it would then move on to the next master folder "Model2".

I
can just run that as a different sub if needs be though...
I don't need to record the VENDCODE results or anything so a

wildcard
there is fine, it's the subfolder searching that's getting me stuck.

I
can do all the workbook specific code... if anyone could supply the
looping subfolder searching bit, that would be excellent.

Thank you,

Gareth


--
pianoman

------------------------------------------------------------------------
pianoman's Profile:

http://www.excelforum.com/member.php...o&userid=33712
View this thread:

http://www.excelforum.com/showthread...hreadid=537137




--
pianoman
------------------------------------------------------------------------
pianoman's Profile: http://www.excelforum.com/member.php...o&userid=33712
View this thread: http://www.excelforum.com/showthread...hreadid=537137

Reply
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
Checking for subfolders and creating Gizmo63 Excel Worksheet Functions 1 August 16th 06 12:46 AM
Auto look through subfolders grewpp Charts and Charting in Excel 1 February 14th 06 02:35 PM
please help me with folder and subfolders pieros Excel Programming 2 November 4th 05 12:52 PM
copy subfolders, replace text in files and save files in copied subfolders pieros Excel Programming 0 November 1st 05 12:08 PM
Get list of subfolders Darren Hill[_3_] Excel Programming 3 March 6th 05 09:28 PM


All times are GMT +1. The time now is 05:17 PM.

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

About Us

"It's about Microsoft Excel"