Dim FSO, f, fc, fj, s, f1
Dim sFolder As String
sFolder = "C:\mydir\" 'makesure there is a ending slash
Set FSO = CreateObject("Scripting.FileSystemObject")
Set f = FSO.GetFolder(sFolder)
Set fc = f.SubFolders
Set fj = f.Files
For Each f1 In fj
s = sFolder & f1.Name
's is the currect file
Next
