Free Support Forum - aspose.com

Avoid Word File Corrupted & End Of Stream Exceptions when Open Save a DOC with C# Code of Aspose.Words for .NET

The attached document is transferred to the system, an error is encountered when you want to view it. Application for scenario testing is attached.
YG14014.zip (134.3 KB)
AsposeTestProjectWord.zip (3.0 MB)

@srmbimser,

You’re right; Aspose.Words for .NET currently throws the following exception upon loading this particular DOC Word document:

Aspose.Words.FileCorruptedException
HResult=0x80131500
Message=The document appears to be corrupted and cannot be loaded.
Source=Aspose.Words
Inner Exception 1:
EndOfStreamException: Unable to read beyond the end of the stream.

For the sake of correction, we have logged this problem in our issue tracking system. The ID of this issue is WORDSNET-21889. We will further look into the details of this problem and will keep you updated on the status of correction. We apologize for your inconvenience.

The issues you have found earlier (filed as WORDSNET-21889) have been fixed in this Aspose.Words for .NET 21.3 update and this Aspose.Words for Java 21.3 update.