private int GetCountFiles(FileInfo rarFileInfo) { return ArchiveFactory.Open(rarFileInfo.FullName).Entries.Count(); }
no tried
int fileCount = 0; var archive = ArchiveFactory.Open(@"C:\Code\sharpcompress\TestArchives\sharpcompress.zip"); foreach (var entry in archive.Entries) { if (!entry.IsDirectory) { Console.WriteLine(entry.Key); fileCount++; } } Console.WriteLine("File count = " + fileCount);
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)