StorageHelper DeleteOldFiles Method (String, DateTime, Boolean)Kentico 8.0 API Reference
Deletes files older than specified time from the file system.

Namespace: CMS.IO
Assembly: CMS.IO (in CMS.IO.dll) Version: 8.0.0.0 (8.0.5239.26125)

Parameters

folder
Type: OnlineSystem String
Folder path
olderThan
Type: OnlineSystem DateTime
Limit time for deletion of a file
deleteEmptyFolder (Optional)
Type: OnlineSystem Boolean
Indicates if the specified folder should be deleted if there are no files left at the end
See Also