+ Reply to Thread
Results 1 to 6 of 6

Creating an Excel list of Excel Files

  1. #1
    Registered User
    Join Date
    05-28-2008
    Posts
    20

    Creating an Excel list of Excel Files

    I have a folder filled with many different excel files.

    Is it possible to create a list, in excel, that populates all of the file names from a folder?

  2. #2
    Valued Forum Contributor Macdave_19's Avatar
    Join Date
    03-14-2007
    Location
    Birmingham, England
    MS-Off Ver
    12.0
    Posts
    808
    This code will go into a set folder and extract all the .xls filenames

    just attach it to a button

    Please Login or Register  to view this content.
    Mr MaGoo
    Magoo.Inc MMVII

    If i've helped please add to my Rep by Clicking on the Blue Scales in the top right hand corner of the post

  3. #3
    Registered User
    Join Date
    05-28-2008
    Posts
    20

    compile error

    I get a compile error with 'Sub Filename()' what do I need to fix?

  4. #4
    Forum Contributor
    Join Date
    02-27-2008
    Posts
    764

    macro to list files

    Hi
    Replace filepath from D:\my documents\ to your folder path and runt the macro
    Please Login or Register  to view this content.
    ravi

  5. #5
    Registered User
    Join Date
    05-28-2008
    Posts
    20
    for some reason it doesn't seem to work. When I run it, it moves down one row with blanks. I realized that they aren't .xls, they're .txt. So i changed the .xls -> .txt.

    Why doesn't this still work?

  6. #6
    Forum Expert
    Join Date
    11-27-2007
    Location
    New Jersey, USA
    MS-Off Ver
    2013
    Posts
    1,669

    List Filenames

    Code provided by Macdave works fine.
    Look at the attached example.
    Enter your path name in K1 [e.g. C:\Sales\Reports] and file type in K3 [e.g. .Doc].
    And click the button.
    List appears in column A.
    modytrane
    Attached Files Attached Files

+ 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