+ Reply to Thread
Results 1 to 3 of 3

Getting all sub folders and files within a folder

  1. #1
    Registered User
    Join Date
    06-09-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2007
    Posts
    92

    Getting all sub folders and files within a folder

    Hello all, I have the following problem:

    I run my sub which opens up a folder browser, however this only gets the folder, when I would like it to get files and sub folders within the folder.

    Please Login or Register  to view this content.
    Any help would be greatly appreciated.
    Last edited by UsmanBPD; 03-05-2013 at 06:02 AM. Reason: wrong code
    Regards,
    Usman.

  2. #2
    Registered User
    Join Date
    06-09-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2007
    Posts
    92

    Re: Getting all sub folders and files within a folder

    BUMP

    I got told to use 'vbNormal' instead of 'vbDirectory' in my code, however nothing changes. Any ideas?

  3. #3
    Forum Expert mike7952's Avatar
    Join Date
    12-17-2011
    Location
    Florida
    MS-Off Ver
    Excel 2007, Excel 2016
    Posts
    3,519

    Re: Getting all sub folders and files within a folder

    Maybe you can adapt this. Change the path below in red. Also make sure you have sheet1 in workbook. Will list all folders/files/subfolders/files.

    Please Login or Register  to view this content.
    Thanks,
    Mike

    If you are satisfied with the solution(s) provided, please mark your thread as Solved.
    Select Thread Tools-> Mark thread as Solved.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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