hi,
i have a word file
after.docx (799.1 KB)
when i used the below code to get the page count:
var aspDocument = new Aspose.Words.Document(tmpFileName);
aspDocument.Save(tmpFileName);
aspDocument = new Aspose.Words.Document(tmpFileName);
if (isUpdatePageLayout)
{
aspDocument.UpdatePageLayout();
aspDocument.UpdateTableLayout();
}
return aspDocument.PageCount;
an exception was thrown:
Aspose.Words.FileCorruptedException: ‘The document appears to be corrupted and cannot be loaded.’
InvalidOperationException: Cannot find part ‘’.
i double checked the document , can’t find any part reference id is empty.
can you please help me on this issue?