Attached is a sample for file for which the Statistics extracted by Aspose.Word is different to what is shown by MS Word, through the Advanced Properties. Following is the summary:
Aspose derived values
As seen from advanced properties in Word
No Of Characters
129
59
No Of Characters With Spaces
150
66
No Of Lines
1
9
No Of Paragraphs
1
4
No Of Words
22
13
Could anyone explain the reason for parity. We’ve noticed that for files that have Unicode data, the parity is higher.
Thanks.
Thanks for your inquiry. Aspose.Words does not update statistics information, it just returns values stored in the document. Here are values of document properties stored in the document:
As you can see Aspose.Words returns values stored in the document.
You can update Characters, CharactersWithSpaces, Words and Paragraphs count by calling Document.UpdateWordCount method: https://reference.aspose.com/words/net/aspose.words/document/updatewordcount/
Unfortunately, there is no way to update Lines count. Your request has been linked to the appropriate issue. You will be notified as soon as this feature will be supported. But I cannot promise you that this feature will be available sometime soon. This quite complex issue and not many customers asked about it yet.
Best regards,