Function to return disk files meeting match criterion

  • Thread starter Thread starter Kevin Sprinkel
  • Start date Start date
K

Kevin Sprinkel

I would like to assign code to a command button that will
create and populate a table with all files meeting a name
criteria, such as "03001E*.*", searching in a passed
folder name, to include all its subfolders.

Does anyone know how to do this?

Thank you for all assistance.
 
Randy Birch has code to do a recursive file search at
http://vbnet.mvps.org/code/fileapi/recursivefiles_minimal.htm although I
don't believe he includes the use of a search criteria in that example.
Hopefully you know how to write the file names to a table once you've
retrieved them.

And my obligatory caution about using Randy's site. It's aimed at VB
programmers, so sometimes the Form-related instructions don't work in Access
(since Access and VB have different form models).
 
Back
Top