/ Forums / Advansys Formativ / Formativ Creator / how can I delete all files in a folder / Reply To: how can I delete all files in a folder
March 21, 2006 at 4:45 pm
#5544
Iterate through all files in the target folder and delete the file. See below the sample code.
set oFSO = Utilities.FileSystem set oIterator = oFSO.FileIterator oIterator.FileSpec = "c:temptest*.*" oIterator.load() for x = 0 to oIterator.Files.Count -1 oFSO.DeleteFileOnDisk(oIterator.Files.strings(x)) next set oFSO = nothing
Hope this helps.
Regards,
Advansys Support