+ Reply to Thread
Results 1 to 5 of 5

Loop through subfolders

  1. #1
    Forum Contributor
    Join Date
    11-04-2012
    Location
    Australia
    MS-Off Ver
    Excel 2016
    Posts
    334

    Loop through subfolders

    I need to run some code on each sub folder in a directory.
    How do I get the code to loop to the next folder.

    Please Login or Register  to view this content.

    Any assistance appreciated.

  2. #2
    Forum Guru karedog's Avatar
    Join Date
    10-03-2014
    Location
    Indonesia
    MS-Off Ver
    2003
    Posts
    2,971

    Re: Loop through subfolders

    Make a recursive call to subfolder, for example :

    Please Login or Register  to view this content.

  3. #3
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,169

    Re: Loop through subfolders

    Hi anrichards,

    See if Power Query does what you need...

    http://excelunplugged.com/2015/02/10...n-power-query/
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  4. #4
    Forum Contributor
    Join Date
    11-04-2012
    Location
    Australia
    MS-Off Ver
    Excel 2016
    Posts
    334

    Re: Loop through subfolders

    Thanks Karedog, problem solved.

    Thanks for the suggestion MarvinP, I will take a look and see if I can adapt for my needs.

  5. #5
    Forum Guru karedog's Avatar
    Join Date
    10-03-2014
    Location
    Indonesia
    MS-Off Ver
    2003
    Posts
    2,971

    Re: Loop through subfolders

    You are welcome, thank you for the rep. points.


    Regards

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Get Value Function Loop through all files in folder and its subfolders
    By Cheeseburger in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 03-27-2016, 06:19 PM
  2. Open file within subfolders and loop
    By brad999 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-07-2014, 02:15 PM
  3. Loop through subfolders
    By Moreno20 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-11-2014, 04:05 PM
  4. loop macro to different subfolders
    By jeffgriffin in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-24-2013, 10:34 AM
  5. Macro to Loop within all subfolders in a folder in three levels
    By sarakhalatbari in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 11-22-2011, 06:20 AM
  6. Loop Thru Wkbks in folder and subfolders
    By Diddy in forum Excel General
    Replies: 2
    Last Post: 10-19-2011, 02:25 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1