Public Class Form1
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
ListBox1.Items.Clear()
Dim dir As New IO.DirectoryInfo(TextBox1.Text)
Dim fname As IO.FileInfo
Dim fname2 As IO.DirectoryInfo
For Each fname In dir.GetFiles()
ListBox1.Items.Add(fname)
Next
For Each fname2 In dir.GetDirectories()
ListBox1.Items.Add(fname2)
Next
End Sub
End Class