Document.UpdateFields query


I have a query about the Document.UpdateFields method in Aspose.Words. It seems that if you have an empty paragraph after a table of contents field, it updates the format of that paragraph end mark.

Please see the code below and the attached .dot files. In the input file ( we have a table of contents followed by 3 empty paragraphs. Please note that the paragraph breaks are red, font size 5. After manually updating fields in MS Word, nothing changes ( However, when using the UpdateFields method, the formatting of the first paragraph break changes to black, font size 11 (

string inputPath = @“D:\”;
var document = new Document(inputPath);

Michal (26.5 KB)


We tested the scenario and have managed to reproduce the same problem on our end. For the sake of correction, we have logged this problem in our issue tracking system. The ID of this issue is WORDSNET-18533. We will further look into the details of this problem and will keep you updated on the status of correction. We apologize for your inconvenience.

The issues you have found earlier (filed as WORDSNET-18533) have been fixed in this Aspose.Words for .NET 19.7 update and this Aspose.Words for Java 19.7 update.