The name of the zip, gzip, tar, or jar archive.
def get_archive_file() -> str: ... def set_archive_file(value: str) -> None: ...
archive_file = property(get_archive_file, set_archive_file)
This property specifies the name of the archive to be read or written. This property is required when extracting files.
When compress is called, the file named by archive_file will be written; if a file of this name already exists the on_overwrite event will be fired. If archive_file is set to the empty string (""), the archive will not be written to disk, and will be provided only through the on_progress event.
The filename may be specified with or without a path. Paths may be relative or absolute, and should be specified in the format native to the host operating system. The filename should be specified with the appropriate extension (such as "zip"); an extension will not automatically be appended by the class.
If the file cannot be read, or written, as appropriate, a trappable error will be generated.
Example (Creating an Archive)
ZipControl.ArchiveFile = "c:\test.zip" ZipControl.RecurseSubdirectories = true ZipControl.IncludeFiles("c:\foo\*") ZipControl.Compress()
Note: an archive already open for read may be closed by setting archive_file to the empty string ("").