Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

creating a zip file

Status
Not open for further replies.

kmm64

Technical User
May 4, 2004
8
US
Hi all,

I'm working on a project that will require a log of files within a directory and its subdirectories be archived in a zip file. I've been searching for different methods to accomplish this but have come up short. If anyone can point me in the right direction I would greatly appreciated it.

Thanks
 
Do you also have the zip program on your machine as well?

--
 
First thing to do is get this -
From a console window, practice generating the ZIP commands which will save all the information which you want saved.

As an example, say you ended up with
[tt] zip c:\zips\file.zip c:\output\today[/tt]

You would transfer this to your code as follows
Code:
system( "zip c:\\zips\\file.zip c:\\output\\today" );
system() is generally not the best API call to use in a windows environment, but it is portable and easy to explain.

--
 
if you don't want to rely on some thirt party installed or not installed software you may use:


Ion Filipski
1c.bmp
 
Thanks alot, two great answers. Guys I really appreciate the help. I'm going to play around with both methods to see which best fits my needs. Thanks again.

kmm64
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top