NobodyWannabe Posted January 19, 2013 Posted January 19, 2013 The single line of code below will delete files over seven days old. Additionally, it runs without the Windows Command Shell opening. The only configuration required is the path to the directory, i.e., C:\PROGRA~1\ABC\Data\Archive. Long file names (C:\Program Files\ABC\Data\Archive) work, as well. To review additional options for "forfiles," Google is your friend. Run(@ComSpec & " /c " & "forfiles /p ""C:\PROGRA~1\ABC\Data\Archive"" /s /m *.* /c ""cmd /c Del @path"" /d -7", @SystemDir, @SW_HIDE)
AdmiralAlkex Posted January 19, 2013 Posted January 19, 2013 What's your question/problem? Or did you mean to post in the examples forum? .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now