johnboy691 Posted April 17, 2008 Report Share Posted April 17, 2008 I've tried reading the book, previous posts and either it's not clicking and/or I'm just to dense....maybe someone can help me. I want a macro to capture the file name, extension and path to a ALL files say in My Documents. I know the path to My Documents, but how do I get the macro to capture all information for EACH file in My Documents? I want to capture it, in variables, then put it into an excel file. Any ideas would be greatly appreciated. Quote Link to comment Share on other sites More sharing options...
kevin Posted April 17, 2008 Report Share Posted April 17, 2008 Here is something to start with: // All the macro commands inside the 'Repeat with Folder' will run for each file in the specified folder Repeat with Folder // Here: T1 will contain the file name. Repeat End <REM2:All the macro commands inside the 'Repeat with Folder' will run for each file in the specified folder><REP3:07:000001:000001:0001:0:01:C:\Documents and Settings\Kevin Heaton\My Documents><REM2:Here: T1 will contain the file name.><ENDREP> Quote Link to comment Share on other sites More sharing options...
Cory Posted April 17, 2008 Report Share Posted April 17, 2008 If you check out my post on my TSV trick and use it in conjunction with Repeat With Folder that will do the trick nicely. I use this with several macros to make various file lists. Quote Link to comment Share on other sites More sharing options...
johnboy691 Posted April 17, 2008 Author Report Share Posted April 17, 2008 Kevin: Thank you, Thank you, Thank you!!! I am red with embarrassment. I can't beleive how easy that was. In two minutes after reading your post I had it running. Again, thanks so very much! John Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.