This website is using cookies. We use cookies to ensure that we give you the best experience on our website. More info. That's Fine
HPC:Factor Logo 

LHA.exe and ZIP.exe 1.00

Open Source
This is software that sends commands to unlha.dll & unzip.dll for WindowsCE to perform compression/decompression.
You must be registered and logged into HPC:Factor in order to contribute to the SCL.


How to use LHA.exe and ZIP.exe.

Thank you for downloading.
This is software that sends commands to unlha.dll & unzip.dll for WindowsCE to perform compression/decompression.

This software does not work alone. To use LHA.exe, unlha.dll must be installed, and to use ZIP.exe, unzip.dll must be installed.

You're probably thinking, "How can I use it without a console?" Well, just do something about it (I guess). By the way, I use it together with nScript.

The command strings to send to LHA.exe and ZIP.exe are explained below.

The format of the command is as follows.

[<command>] [[-<switch>[+|-|0|1|2]]...] <archive_file_name>[.LZH]
[[<base_directory_name>\] [<path_name>|<wild_name>]...]]...

command: command
switch: switch
archive_file_name : Archive name
base_directory_name : Base directory
path_name : path (file) name
wild_name : wildcard

If path_name contains half-width spaces,
Please surround it with double quotes " ".
(Of course, if there are no half-width spaces, you can also surround it with " "
will be recognized correctly)

ex. "a \test.lzh "\My Documents\test.txt""

a: Add file to archive

Compress files and store them in the archive. The second argument is the output destination.
file name. Third, specify the reference directory (only if necessary).
Specify the fourth and subsequent files you want to compress.
Wildcards can also be used halfway.
For more information about the reference directory, see About the reference directory below.
Please refer to.

ex. -Example without using standard directory-
"a \test.lzh \test\*.*"
? Save the file under the \test directory with the name test.lzh.
"a \test2 \test\*.dll"
? The name is test2.lzh, and the extension is in the \test directory.
Compress .dll files.

e or x: Extract files in the archive

Expand the archive. The second argument is the name of the archive you want to expand, the third argument is
Specify the directory to unzip.
However, if the destination directory does not exist, the DLL will
It does not try to create it and exits with an error.
Therefore, please create it in advance on the software side.
Inside the DLL, the archive file is inspected before the extraction process.

ex. "e test.lzh \test\"
? Extract the archive called test.lzh to the \test folder.

t: Archive integrity check

Check whether the archive can be expanded correctly.
For lzh archives, header checks, CRC comparisons, etc. are performed.
For zip archives, only the header is checked.
(Then it can't be called an integrity test.)

ex. "t \test.lzh"
? Check the integrity of test.lzh.

l: Output list of archive contents

Outputs the list of archive contents to the output buffer.
The format is as follows.

-------- ---- -------- ------ ------ ----- -----------------
00000000 STOR 0 ****** 2002-03-06 7:06:38 test/test2/
E3C740A7 DEFL 23444 32.5% 2002-03-03 9:21:12 test/test2/test2.txt
17F811C2 DEFL 12079 29.3% 2002-03-03 9:20:52 test/test.txt
-------- ---- -------- ------ ------ ----- -----------------
Total 35523 3files

The words that go into TYPE are different for unlha.dll and unzip.dll.

For LHA, use the leading and trailing hyphens, such as "lh0" and "lh5".
Display in abbreviated form.

For ZIP,
STOR - Store
DEFL - Deflate
SRNK - Shrunk
RED1~4 - Reduce 1~4
IMPL - Implode

is shown.

q: silent mode

If you specify this option together with "a" or "e",
Execute processing without displaying the status display dialog when compressing/expanding.

ex. "eq \test.lzh"
? Extract test.lzh without displaying the dialog.

f: Force overwrite

When unzipping, if you try to overwrite a file, you will be prompted to confirm it.
A dialog will appear (even if the "q" option is specified)
This dialog will appear). There are 4 options. "Yes" overwrites and decompresses
"No" continues processing the next file without overwriting. “Yes to all”
Overwrite and unzip all subsequent files, "Skip" does not overwrite,
Exits without any further processing.

If you specify this option together with "e", this dialog will not be displayed and
Everything will be overwritten and unzipped.

ex. "ef \test.lzh"
? Expand test.lzh. All existing files will be overwritten.

o: Specify compression algorithm
(0|5|6|7) - Unlha
(0-9) - UnZip

If this option is specified together with "a",
You can specify the compression algorithm for compression.

Can be specified: 0 (no compression), 5 (-lh5-), 6 (-lh6-), 7 (-lh7-)
is. If omitted, it will be compressed with -lh7-.

You can specify from 0 to 9. 0 is no compression.
1 gives highest priority to speed and lowest compression ratio; 9 gives highest priority to compression ratio and lowest speed.
If omitted, it will be compressed by 6.

ex. "ao5 test.lzh test.txt"
? Compress test.txt in -lh5- format.

About the reference directory

WindowsCE does not have the concept of a current directory, so all
The path must be specified using an absolute directory.
Therefore, when compressing/decompressing, use the concept of reference directory.
Use as an alternative to relative paths.
When specifying the base directory, be sure to end with \.
Otherwise, it will incorrectly think that the file is specified.

For example, for compression,
a \Dir1\Dir2\test.lzh \Dir1\ \Dir1\Dir2\test.txt
, when the standard directory is specified ( \Dir1\ ), Dir2 and the files under Dir2 are
The specified file will be stored in the archive.

Suppose this
a \Dir1\Dir2\test.lzh \Dir1\Dir2\test.txt
, if no reference directory is specified, from Dir1 to the archive
It will be stored.

For unzipping,
e "\Storage Card\test.lzh" \temp If specified, test.lzh will be unzipped under \temp.
\temp\ specifies the base directory.


zipOpen SourceLHAunzip

License Open Source
The program is open source, free and the source code is available on-line.
Website http://hp.vector.co.jp/authors/va023546/
This link is no longer available on the World Wide Web and will attempt to load via the WayBack Machine
Released 24 March 2002
Popularity 2994
Total Downloads  0
Submitted By torch
Submitted On 21 February 2024


No comments have been submitted against this application. Be the first!

You must be signed-in to post comments in the SCL. Not registered? Join our community.

Software Compatibility List: The SCL is provided for free to the Handheld PC Communty and we do not carry advertising to support our services. If you have found the SCL useful, please consider donating.