I want to import all the file names in a folder into a listbox. I want to do it without any user input and the number of files will vary.
Any ideas?
Sam
Printable View
I want to import all the file names in a folder into a listbox. I want to do it without any user input and the number of files will vary.
Any ideas?
Sam
Welcome to the forums. :wave:
Using what?
VB6?
VB.NET?
Something else?
Ah, VB 6.0. Sorry :-)
This was just asked last week:VB Code:
Private Sub Form_Load() Dim s As String s = Dir("E:\VB\*.*") 'whatever path you want Do While s > "" List1.AddItem s s = Dir Loop End Sub