Results 1 to 4 of 4
  1. #1
    Join Date
    Apr 2004
    Posts
    130

    Unanswered: Import File Names in Folder

    I want to import only the file names and file dates of files in a specific folder into an MS Access table. Not the data, just the file name and file date. Anyone got any ideas how to do this?
    thanks,
    Winston

  2. #2
    Join Date
    Jun 2006
    Location
    Colton, CA
    Posts
    26
    You need to use the FSO (File System Object) to get the filedate, and with the FSO you can also get the filename.

    Do a search on google or msdn.microsoft.com for FSO
    Geek it till it mHz

  3. #3
    Join Date
    Feb 2004
    Location
    Chicago, IL
    Posts
    1,312
    An alternative is using the Dir function and the FileDateTime function. Dir is a little weird, but I think help will explain it well enough.

  4. #4
    Join Date
    Apr 2004
    Location
    outside the rim
    Posts
    1,011

    A "quick and dirty" approach

    If you only need to do this once, open a DOS prompt (a "Command Window" for the younger folks), navigate to the directory and use this command:
    Code:
    DIR *.*>FileList.txt
    This will return the directory listing, including the date and file size, into a character delimited text file, which you can then open in anything, including Excel or directly from Access if you really want to.

    I suppose it will work using the shell command as well - never tried it.

    tc

Posting Permissions

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