Solved

How to unzip a .zip file (using C++ builder)

Posted on 2003-11-24
9
1,477 Views
Last Modified: 2008-03-17
Hi, I need to know how can I unzip a file located in C:\Program files\ to this same directory, but I can't have any dialogs being shown during the process.

Cheers
0
Comment
Question by:luizblink182
9 Comments
 
LVL 3

Expert Comment

by:monkesdb
ID: 9815964
you need to get zlib or zziplib. zlib is the full thing whereas zziplib is a thirdparty lightweight alternative

http://www.gzip.org/zlib/
http://zziplib.sourceforge.net/

you should find examples on how to use them on their sites
0
 

Author Comment

by:luizblink182
ID: 9816452
I already tried to use those. No success.
0
 
LVL 2

Expert Comment

by:JensUniweb
ID: 9817345
http://www.info-zip.org/ is another library for zip files.
0
 
LVL 2

Expert Comment

by:JensUniweb
ID: 9817354
gzip and zip are diffrent things. And now zip have there version 9 which is not compatable with the old versions. I don't think info-zip supports zip version 9.
0
Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

 

Author Comment

by:luizblink182
ID: 9818187
I didn't get how to use these libraries.

Can anyone give me the code to extract a zip file into a specified directory? That's all I need.
0
 
LVL 16

Accepted Solution

by:
George Tokas earned 50 total points
ID: 9826273
0
 
LVL 2

Assisted Solution

by:JensUniweb
JensUniweb earned 50 total points
ID: 9830187
Is it realy code you need or how you use them in your enviroment?? What enviroment are you using. Windows, Unix? GCC, VC++, VC .NET, BCB or any other?

Look at this link for some code. Don't know if that helps you.

http://www.stillhq.com/cgi-bin/cvsweb/~checkout~/howto-zlib/example.c?rev=1.1.1.1&content-type=text/plain
0
 
LVL 9

Expert Comment

by:tinchos
ID: 10285803
No comment has been added lately, so it's time to clean up this TA.
I will leave the following recommendation for this question in the Cleanup topic area:

Split: gtokas {http:#9826273} & JensUniweb {http:#9830187}

Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

Tinchos
EE Cleanup Volunteer
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

Often, when implementing a feature, you won't know how certain events should be handled at the point where they occur and you'd rather defer to the user of your function or class. For example, a XML parser will extract a tag from the source code, wh…
Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now