I want to zip a couple of files in a folder and also extract those with C#.

Posted on 2011-10-31
Last Modified: 2012-05-12
Hi there;

I want to zip a couple of files in a folder and also extract those with C#.

I am not eager to use a 3rd party library.

How can I manage this with  .NET framework itself?

If not, how can I achieve this -->without<-- using DotNetZip (


Question by:jazzIIIlove
    LVL 69

    Assisted Solution

    by:Éric Moreau

    Assisted Solution


    i have done a lot of my work related to zipping and unzipping folders and files on server using

    this is opensource c# library you can use it as it is without fear..

    Kapil Joshi
    LVL 12

    Author Comment

    Hi there;

    Thanks for the interest.

    Is there any issue regarding the file size? I mean my files may be larger than a couple of hunderd megabytes. In such, which one is suitable or not suitable?

    LVL 11

    Accepted Solution

    My preference is for DotNetZip:

    There is mention that sharpziplib has a 2.2GB limitation and there is an inherent 4GB limitation in the standard zip format (which would apply to dotnetzip).  DotNetZip however, supports the zip64 format:

    Featured Post

    Find Ransomware Secrets With All-Source Analysis

    Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

    Join & Write a Comment

    Extention Methods in C# 3.0 by Ivo Stoykov C# 3.0 offers extension methods. They allow extending existing classes without changing the class's source code or relying on inheritance. These are static methods invoked as instance method. This…
    It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
    how to add IIS SMTP to handle application/Scanner relays into office 365.
    Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

    746 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

    20 Experts available now in Live!

    Get 1:1 Help Now