Skip to main content

ZipArchive.AddDirectory(String, String) Method

Recursively add files and directories to the archive.

Namespace: DevExpress.Compression

Assembly: DevExpress.Docs.v23.2.dll

NuGet Package: DevExpress.Document.Processor

Declaration

public ZipDirectoryItem AddDirectory(
    string path,
    string archivePath
)

Parameters

Name Type Description
path String

A string that is the path to a directory which will be included in the archive.

archivePath String

A string that is the path in the archive.

Returns

Type Description
ZipDirectoryItem

A ZipDirectoryItem that is the zip item container for the directory. Currently, the method always returns null.

Remarks

The AddDirectory

recursively collects all files and folders starting from the folder specified by the path parameter. The tree of directories and files is added to the archive directory specified by the archivePath parameter. If the archivePath parameter is set to “/“, the tree is added to the archive root. If the archivePath parameter is null, the last component of a path is used as the name of the archive directory in which a tree is built .

See Also