Sub KillAllFiles()
Dim i As Integer
With Application.FileSearch
.NewSearch
.LookIn = "C:\Excel\Delete These"
.FileType = msoFileTypeAllFiles
.SearchSubFolders = True
If .Execute > 0 Then
For i = 1 To .FoundFiles.Count
Kill .FoundFiles(i)
Next i
End If
End With
End Sub
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.