Problem with Total pages in a Page numbering

Dear sir, madam,
I have a problem with page numbering, more specifically with the total number of pages. As you can see in the attached document, the total number of pages isn’t correct on the first page. Is there any way to get this working correctly? I use the newest version of Aspose.Words and an xml preprocessor to build word documents from a client xml file. Right before I create the output document (through document.save()) I do a document.updateFields(). This, however, doesn’t seem to take the total page numbers into account. If I update the fields in Microsoft Word directly it gives the correct number of total pages.

Hi
Thanks for your request. There is IF field in your footer. Unfortunately Aspose.Words does not evaluate IF field at the moment. This feature will be supported in one of the future releases. As a workaround you can use just PAGES field.
Best regards.