To unzip a uploaded file in mvc?
3 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Guest UserRank #816 · 2.8K reputationPosted Jun 11, 2015, 11:00 PM EDT
Jithil JohnRank #2,791 · 506 reputationPosted Jun 15, 2015, 1:39 AM EDT
Manoj BhoirRank #599 · 4K reputationPosted Jun 15, 2015, 2:22 AM EDT
using System; using System.IO; using System.IO.Compression; namespace ConsoleApplication { class Program { static void Main(string[] args) { string startPath = @"c:\example\start"; string zipPath = @"c:\example\result.zip"; string extractPath = @"c:\example\extract"; ZipFile.CreateFromDirectory(startPath, zipPath); ZipFile.ExtractToDirectory(zipPath, extractPath); } } } For more info check this link : https://msdn.microsoft.com/en-us/library/hh485723%28v=vs.110%29.aspx