Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
Packages and Libraries
»
paszlib. Determine if extraction was successful
Free Pascal
Website
Downloads
Wiki
Documentation
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Documentation (RTL/FCL/LCL)
Bugtracker
CCR Bugs
GIT
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
Forum Rules
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
Search
Advanced search
Recent
Perlin Noise Map With BGR...
by
Boleeman
[
Today
at 01:36:13 pm]
Lazarus for Windows on aa...
by
Thaddy
[
Today
at 01:35:48 pm]
Strange Error when I use ...
by
Thaddy
[
Today
at 01:33:23 pm]
Strange Mail from memo.mi...
by
Thaddy
[
Today
at 01:27:19 pm]
[Solved] Lazreport. Sorti...
by
Petrus Vorster
[
Today
at 11:39:09 am]
Regarding the issue of de...
by
Martin_fr
[
Today
at 11:16:29 am]
[Windows] UTF8 encoding w...
by
Thaddy
[
Today
at 10:42:15 am]
Pleas help, Synapse / Ind...
by
patyit
[
Today
at 10:25:29 am]
would multi threading hel...
by
speter
[
Today
at 09:42:28 am]
Default, Manual Initializ...
by
Okoba
[
Today
at 09:17:22 am]
How to observe the value ...
by
yinhuajian
[
Today
at 05:50:14 am]
Cannot see unit text - ed...
by
lorenzo
[
Today
at 04:05:13 am]
AdvancedHTTPServer: A Go-...
by
egsuh
[
Today
at 01:44:33 am]
What's wrong with my appl...
by
VisualLab
[
Today
at 01:04:16 am]
ThemeServices.OnThemeChan...
by
440bx
[
Today
at 12:16:35 am]
Cross Compile for Dos on ...
by
PascalDragon
[January 20, 2026, 10:54:36 pm]
Feature announcement: Fun...
by
PascalDragon
[January 20, 2026, 09:50:39 pm]
Access violation during d...
by
PascalDragon
[January 20, 2026, 09:49:09 pm]
IStringList...
by
PascalDragon
[January 20, 2026, 09:35:54 pm]
Strings in Free Pascal: I...
by
PascalDragon
[January 20, 2026, 09:33:09 pm]
Developing FreePascal on ...
by
HKPhysicist
[January 20, 2026, 08:59:53 pm]
Anti "churning" in solita...
by
andersonscinfo
[January 20, 2026, 08:37:14 pm]
[Solved] Exception in TFi...
by
d.oertel
[January 20, 2026, 06:18:05 pm]
Animated Sine Beziers
by
Boleeman
[January 20, 2026, 02:34:32 pm]
PadXml 1.0.0 – Portable A...
by
AlexanderT
[January 20, 2026, 02:04:18 pm]
« previous
next »
Print
Pages: [
1
]
Author
Topic: paszlib. Determine if extraction was successful (Read 258 times)
LemonParty
Sr. Member
Posts: 393
paszlib. Determine if extraction was successful
«
on:
November 07, 2025, 12:35:03 pm »
I use TUnZipper.UnZipAllFiles to extract archive.
How to determine if extraction of all files was successful?
Logged
Lazarus v. 4.99. FPC v. 3.3.1. Windows 11
wp
Hero Member
Posts: 13334
Re: paszlib. Determine if extraction was successful
«
Reply #1 on:
November 07, 2025, 01:11:45 pm »
The unzipper raises a lot of exceptions. So, if your unzipping procedure reaches its end without an exception it must have been successful. Untested:
Code: Pascal
[Select]
[+]
[-]
uses
Zipper
;
function
UnzipFiles
(
AZip
:
String
;
AOutputDir
:
String
;
out AErrorMsg
:
String
)
:
Boolean
;
var
UnZipper
:
TUnZipper
;
begin
Result
:
=
true
;
AErrorMsg
:
=
''
;
UnZipper
:
=
TUnzipper
.
Create
;
try
try
UnZipper
.
FileName
:
=
AZip
;
UnZipper
.
OutputPath
:
=
AOutputDir
;
UnZipper
.
Examine
;
UnZipper
.
UnZipAllFiles
;
except
on E
:
Exception
do
begin
AErrorMsg
:
=
E
.
Message
;
Result
:
=
false
;
end
;
end
;
finally
UnZipper
.
Free
;
end
;
end
;
end
.
Logged
Thaddy
Hero Member
Posts: 18703
To Europe: simply sell USA bonds: dollar collapses
Re: paszlib. Determine if extraction was successful
«
Reply #2 on:
November 07, 2025, 01:35:11 pm »
Quote from: wp on November 07, 2025, 01:11:45 pm
The unzipper raises a lot of exceptions.
Oops, that needs a rewrite then.
Logged
If Europe sells their USA bonds the USD will collapse. Europe can affort that given average state debts. The USA can't affort that. Just an advice...
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
Packages and Libraries
»
paszlib. Determine if extraction was successful
TinyPortal
© 2005-2018