2
Reply

Problem with extract files in c#

Ask a question
TheMrRAfus

TheMrRAfus

11y
1.1k
1
Hello , i´m trying to extract all contents of a .jar files with CsharpZipLib

This is my code:



            string appdata = System.Environment.GetFolderPath(System.Environment.SpecialFolder.ApplicationData);
            string subFolderPath = System.IO.Path.Combine(appdata, ".minecraft");
            string bin = System.IO.Path.Combine(subFolderPath, "bin");
            string mc = System.IO.Path.Combine(bin, "minecraft.jar");
            string test = System.IO.Path.Combine(subFolderPath, "aa");
          

            using (ZipFile zip = ZipFile.Read(mc))
            {
                foreach (ZipEntry e in zip)
                {
                    e.Extract(test);


When I execute the project only extract some folders, not all, I want to extract all folders and files in the .jar


Thanks

Answers (2)