Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.
One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.
Dim objFSO: Set objFSO = CreateObject("Scripting.FileSystemObject") strSourceFolder = "F:\Common\Scans\" iDaysOld = 0 dtOld = DateAdd("d", -iDaysOld, Date) Set objFLD = objFSO.GetFolder(strSourceFolder) For Each fld In objFLD.SubFolders Set objSub=objFSO.GetFolder(fld) For Each subFld in objSub.SubFolders ProcessFolder (objFSO.GetFolder(subFld)) Next If objSub.Size = 0 Then objFSO.DeleteFolder objFLD.Path Set objSub=Nothing Next Set objFSO = Nothing wscript.quit Sub ProcessFolder(strSource) ProcessFiles strSource For Each fld In strSource.SubFolders ProcessFolder objFSO.GetFolder(fld) Next End Sub Sub ProcessFiles(strSrc) For Each fil In strSrc.Files If DateDiff("d", fil.datelastaccessed, dtOld) >= iDaysold Then objFSO.DeleteFile fil.Path End If Next End Sub
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.