Forum Discussion
Importing Multiple Text Files
The short answer, of course, is yes you can do that.
The long answer is that it will require VBA and functions that can enumerate files in a folder (preferably using FileScripting, although old school Dir is feasible). Then, once you've created a list of those files in a temp table, you can loop through the list importing each one in turn.
However, it also depends on WHY you need to do this. If the files are constantly being replaced by an external process, such as output from a testing station, or orders from an online store application, then you can't just link to them and use them that way, not easily at any rate.
I believe that at least two of the projects I completed for clients over the years would be similar to this, but each involves multiple, significant VBA functions and subs and would not be something easily passed through a forum.
So, define the nature of the requirement a little more fully and we can maybe offer more ideas.
- George_HepworthMar 29, 2022Silver ContributorIt's in half a dozen procedures scattered over different modules and it is highly specific to one environment. It took a couple of weeks to work it all out and implement the supporting form.
I can make it available as is, but it'll be up to you to implement the concepts.