We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

InvalidOperationException when opening specific DotX files

Hi,


the following code throws InvalidOperationException when opening the attached DOTX files.

var doc = new Document(inputStream);
var info = doc.GetPageInfo(0);

Here are the exception details:
- Exception thrown: ‘System.InvalidOperationException’ in Aspose.Words.dll
- Additional information: "This operation requires the node to be inside the main document."

tested with Aspose.Words.dll for .NET version 17.5

After getting the page information I expect to be able to render these documents.

Best Regards,
Vassil

Hi Vassil,


Thanks for your inquiry.

While using the latest version of Aspose.Words i.e. 17.5, we managed to reproduce this problem on our end. We have logged the following three issues in our bug tracking system.

WORDSNET-15466: to fix the problem with admin.dotx
WORDSNET-15467: to fix the problem with admin1.dotx
WORDSNET-15468: to fix the problem with OBJECTIVE.dotx

Your thread has also been linked to these issues and you will be notified as soon as they are resolved. Sorry for the inconvenience.

Best regards,

@DWProject,

The issues you have found earlier (filed as WORDSNET-15466, WORDSNET-15467 and WORDSNET-15468) have been fixed in this Aspose.Words for .NET 17.7 update and this Aspose.Words for Java 17.7 update.