Copyright © 2006-2019 MultiMedia Soft

ZIP.EntryExtractToFile method

Previous pageReturn to chapter overviewNext page

Remarks

 

Extracts into a file on disk a specific entry available inside a ZIP file session previously opened through the ZIP.Open method or created through the ZIP.Create method.

 

A successful call to this method will fire the ZipOperationStart event followed by a number of ZipOperationPerc events and finally by the ZipOperationDone event.

 

For further details about methods for ZIP management refer to the ZIP object.

For details about using ZIP management refer to the How to manage ZIP files tutorial.

 

 

Syntax

 

[Visual Basic]

control.ZIP.EntryExtractToFile (

strEntryName as String,

strPassword as String,

strDestPath as String,

bAddRelativePathToDest as enumBoolean

) as enumErrorCodes


 

[C++]

short control.ZIP.EntryExtractToFile (

LPCTSTR strEntryName,

LPCTSTR strPassword,

LPCTSTR strDestPath,

short bAddRelativePathToDest

);


 

 

Parameter

Description

 

 

strEntryName

String representing the name of the entry to extract.

strPassword

String containing the optional password for accessing the requested entry; leave it empty if not needed.

strDestPath

String representing the destination path on disk for the given entry

bAddRelativePathToDest

Boolean flag determining if the relative path of the given entry should be added to the destination path.

Supported values are the following:

Mnemonic constant

Value

Meaning

BOOL_FALSE

0

The relative path of the entry is not added.

If for example the strEntryName parameter should be "first_dir/second_dir/myFile.mp3" and the strDestPath parameter should be "c:\myfolder", the final pathname of the extracted file would be "c:\myfolder\myFile.mp3"

BOOL_TRUE

1

The relative path of the entry is added.

If for example the strEntryName parameter should be "first_dir/second_dir/myFile.mp3" and the strDestPath parameter should be "c:\myfolder", the final pathname of the extracted file would be "c:\myfolder\first_dir\second_dir\myFile.mp3"

 

 

Return value

 

Value

Meaning

 

 

Negative value

An error occurred, check the LastError property value in order to get the error code

enumErrorCodes.ERR_NOERROR (0)

The method call was successful