I was trying to resolve my issue in listing a files from a text file to another folder. The script open a file named ".ini" which contain a parameters. The script will use the parameters to copy all files from the list file.
Dim export_file, item, path, extension

Set objFSO = CreateObject("Scripting.FileSystemObject")

Set objPath = objFSO.GetFolder(path)

Set objNewFile = objFSO.CreateTextFile(export_file, True)

sExtension = objFso.GetExtensionName(extension)

Set colFiles = objPath.Files
               For Each Item in colFiles
               If objFSO.GetExtensionName(Item.Name) = sExtension Then 
               objNewFile.WriteLine Item.Name
               End If


Last edited by shabbir; 13Apr2012 at 09:18.. Reason: Code blocks