Thank you for the detailed description of the issue.
Actually I am wondering whether I miss something in reproducing the issue as I tested your code and I successfully saved a .zip file on my local drive. Also to check whether the stream is OK I tried to save it by using a FileStream:
LibrariesManager manager = LibrariesManager.GetManager();
(ZipFile zip =
// ZipFile = Ionic.Zip.ZipFile
IQueryable<Document> docList = manager.GetDocuments().Where(d => d.Status == Telerik.Sitefinity.GenericContent.Model.ContentLifecycleStatus.Live);
// documents is a List of Telerik.Sitefinity.Libraries.Model.Document objects
var stream = manager.Download(doc);
FileStream fileStream =
// Fill the bytes array with the stream data
 bytesInStream =
stream.Read(bytesInStream, 0, bytesInStream.Length);
// Use FileStream object to write to the specified file
fileStream.Write(bytesInStream, 0, bytesInStream.Length);
//zip.AddFileStream(doc.Title + doc.Extension, "", stream);
However there is no method zip.AddEntry()
in version 4.2. Instead I used zip.AddFileStream
as you can see in the code above.
Please let me know if I miss something.
All the best,
the Telerik team
Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward!
We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>