Problem with Page Count in Aspose.Word.Document


#1

When I call out to the Pages property of an Aspose.Word.Document I always get 1 back. I read in a previous post that this is a property of Word and cannot be controlled by Aspose. Is there another way I could obtain the page number count? Perhaps the number of page breaks plus one, or something else?

Thanks


#2

In MS Word 'Pages' value is set to one when document is created and is recalculated only when you are trying to access it using the corresponding menu command (File | Properties | Statistics).

Number of forced page breaks does not provide enough information on total number of pages in the document, because most of pages are not divided by forced break but rather laid out by MS Word pagination engine.

Aspose.Words does not have a pagination engine of its own yet but it will be implemented very soon with the release of Aspose.Words.Viewer.