I need to track documents placed on a shared drive. I have
tblFiles.[filename] and frmFiles.txtfilename. My goal is to have an
updatable list of the complete path for every file in a particular
directory,
no matter which folder/subfolder.
I was able to do this easily for files in the directory, but files in the
folders/subfolders create a problem. I think it could be done using
nested
loops and the dir() function, but I am not sure how to check for the
folders.
S:\myfolder\mysubfolder\myfile.xls
S:\myfile.mdb
S:\myfolder\myfile.doc
--
Teach me to fish! Thanks for the help.
Pax, M
Dennis said:
So if I understand you properly, you only want to input the LAST folder
name,
and have the computer search through all folders for that last one? So if
you
had this path:
C:\Dir1\Dir2\Dir3\Dir4\Dir5\MyDir
You'd only want to enter "MyDir", and have the PC search the entire
directory structure for any instances of "MyDir"?
Is that right?
If so, how would you handle multiple "MyDir" entries in different paths?
Also, are you aware of the overhead and duration that a SEARCH generates?
Are
your users willing to wait 2-5 minutes (for large directory trees)?
:
I am using dir() with arguments for the directory and folder from input
boxes.
Dir(directory & ":\" & filefolder & "\*.*") I am then placing this in
a
table, if this document is not in the table as yet.
I would like to use an input box for the directory, but have it search
through folders and subfolders without having to input a folder name.
Any help is appreciated.