By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,640 Members | 2,279 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,640 IT Pros & Developers. It's quick & easy.

C++ and ZIP Help

100+
P: 134
i have a couple questions

1.how do you create a zip file in c++
2.how do you create files in the zip in c++

i know you can create a folder with
CreateDirectory("C:\\folder",0);
and
create a file with ofstream

anyone have an idea?
thanks
Aug 6 '07 #1
Share this Question
Share on Google+
3 Replies


gpraghuram
Expert 100+
P: 1,275
i have a couple questions

1.how do you create a zip file in c++
2.how do you create files in the zip in c++

i know you can create a folder with
CreateDirectory("C:\\folder",0);
and
create a file with ofstream

anyone have an idea?
thanks
Hi,
If u want to create a zip file in c++ then search for some libraries which u can integerate in ur code.
With the libraries ur life wlll be easy
Raghuram
Aug 7 '07 #2

archonmagnus
100+
P: 113
Otherwise, you could look up the *.zip file specifications [I know they have to start with the ASCII string, "PK", followed by an integer version number] and implement the LZW compression algorithm on whatever files you needed to compress and store the result as a *.zip file.

This result is especially good if you are interested in methodology rather than ease of programming.
Aug 7 '07 #3

100+
P: 134
thanks to you both for your help
Aug 7 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.