8 replies
by nitemare
Hi,
I haven't seen a way to do this the way you mean, but you could:
1. Create a folder to store the data you want to delete.
2. Write a script to move the data to the folder.
3. Schedule a task in Scheduled Tasks/AT to delete all the contents of the folder every X days.
Regards,
by rjackson
by mark
by rjackson
by rjackson
by sritter
This is easily done with a vb script.
Here is some sample code.
Set wshShell = WScript.CreateObject("WScript.Shell")
Set fsObj = CreateObject("Scripting.FileSystemObject")
' Location of Folder that contains files
thisDir = "D:\test"
' Findall files in the directory
Set f = fsObj.GetFolder(thisDir)
Set fc = f.Files
For Each fl in fc
' If a file is older than 13 days kill it.
If (Now - fl.DateCreated) > 13 Then
fsObj.DeleteFile fl.name
End If
Next
by rjackson
by rjackson
This discussion is closed to new replies.
Trending Windows Forum posts
Sort by Trending