Function GetFolderList(folderspec) Dim fso, f, f1, fc, s Set fso = CreateObject("Scripting.FileSystemObject") Set f = fso.GetFolder(folderspec) Set fc = f.Files For Each f1 in fc s = s & f1.name s = s & "\n" Next GetFolderList = s End Function