DocumentBuilder.InsertStyleSeparator does not work when using style from template

See attached sample which uses “DocumentBuilder.InsertStyleSeparator”: (4.9 MB)

The first code snippet is based on and works fine.

The second snippet loads a word document file where the two styles are already defined. Here, the full text line has the same style, and the style separator is placed at the end of the line - not at the position where I created it.

Do you have an idea what went wrong? Is there something special to keep in mind when defining the styles in the word template?

Best regards



We have tested the scenario and have managed to reproduce the same issue at our side. For the sake of correction, we have logged this problem in our issue tracking system as WORDSNET-19622. You will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.

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

Thanks, I can confirm that it works now. Many thanks again for the fast fix.

Best regards