- Hot Topics
Excel Excel VBA - Listbox populated with file names - Search and import
Hey folks! I've made a listbox populated with xlsx files from a specific directory. Inside these excel files are informations about users (name, address, phone numbers, etc.) 9 cells total (A1 to A9). Let's say the folder which the xlsx files are stored contains about 500 files. Every file looks the same. My questions are: How can I search these files (filename) with instant update in listbox? (f.e. if I type the letter 'J' into the searchbox, John will be the only one on the list.) and How can I populate cells in Sheet4 (A1 to A9) from a file on the list? (Basically pulling information about John from his xlsx file for example) Here's what I'm working on. Here's the code for the listbox. Code: Private 'Code End Sub Private Sub UserForm_Initialize() Dim fileList() As String Dim fName As String
This question generated 26 answers. To proceed to the answers, click here.
This thread is current as of June 22, 2014.
For more resources for Microsoft Excel:
This article includes the following tags:
- Microsoft Excel