IZipArchive.AddFile

Syntax

AddFile(FilePath: String; ArchPath: String): IZipArchiveEntry;

Parameters

FilePath. Path and name of the file that must be added to archive.

ArchPath. Path to the archive folder and the file name, with which the FilePath file is added to archive.

Description

The AddFile method adds the specified file to archive.

Comments

Empty value cannot be passed as a value of the ArchPath parameter. The current or a new file name must be specified in ArchPath. The user can also specify the path to the archive folder, to which the file must be added, for example, Folder/SubFolder/NewFileName.txt.

Example

The example of use is given in description of the ZipArchive.Create constructor.

See also:

IZipArchive