Components All New MacOS Windows Linux iOS
Examples Mac & Win Server Client Guides Statistic FMM Blog Deprecated Old

Archive.FileList

Lists file paths in the archive.

Component Version macOS Windows Linux Server iOS SDK
Archive 9.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes ✅ Yes
MBS( "Archive.FileList"; Archive { ; Passphrase; Options } )   More

Parameters

Parameter Description Example Flags
Archive Either container with archive or native file path. "C:\test\test.zip"
Passphrase Password to use. Optional
Options The options to pass to reader.
This is a comma-separated list of options. Option names can be prefixed with module name.
Optional

Added in version 14.3.

Result

Returns list or error.

Description

Lists file paths in the archive.
Please use Archive.Content if you need more details.
This provides file list, which you can filter and then pass to Archive.Extract.

Examples

Get file list:

Set Variable [ $list ; Value: MBS("Archive.FileList"; If(IsEmpty($Path); $Container; $Path)) ]
If [ MBS("IsError") ]
    Show Custom Dialog [ "Failed to read container" ; $list ]
Else
    Set Variable [ $Content ; Value: MBS("JSON.Colorize"; $list) ]
End If

List files with using Windows ANSI encoding:

MBS( "Archive.FileList"; "/Users/cs/Desktop/test.zip"; ""; "hdrcharset=cp1252")

List files with using Japanese CodePage text encoding for older zip archive:

MBS( "Archive.FileList"; "/Users/cs/Desktop/test.zip"; ""; "hdrcharset=cp932")

See also

Release notes

Blog Entries

This function checks for a license.

Created 8th December 2018, last changed 5th September 2025


Archive.ExtractFile - Archive.GZipDecompress