Single File System: Virtual File System Delphi Library
for Archive / Backup with Transparent Compression and Strong Encryption


Deletes the files from SFS file.

function DeleteFiles(Path: string; Attr: Integer = faAnyFile; bRecursive: Boolean = True): Integer;

DeleteFiles deletes files from Path in SFS file.
The return value is a number of deleted files.

The Path parameter is a path within SFS file. It may be a name of the folder or file to delete (wildcards '*' and '?' are allowed).

The Attr parameter specifies the special files to include in addition to all normal files. Choose from these file attribute constants when specifying the Attr parameter:

Constant   Value      Description

faReadOnly   $00000001   Read-only files
faHidden   $00000002   Hidden files
faSysFile   $00000004   System files
faVolumeID   $00000008   Volume ID files
faDirectory   $00000010   Directory files
faArchive   $00000020   Archive files
faAnyFile   $0000003F   Any file

Attributes can be combined by adding their constants or values. For example, to delete read-only and hidden files in addition to normal files, pass (faReadOnly + faHidden) as the Attr parameter.

The bRecursive parameter specifies whether subdirectories of the source path are deleted. All subfolders of the source path are deleted by default.

© 2000-2004 AidAim Software LLC Single File System: