We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

TextColumn is changed after using DocumentBuilder.InsertDocument

I have two documents that I want to merge.
The second document has images and text with two columns.
After appending the second document to the first one the text is not shown with two columns anymore.
This used to work fine with the previous version we used(16.11) and now in version 19.11 it is not working anymore.
Here is the code I’m using:

    Dim aw As New Aspose.Words.Document
    'Load first document
    aw = New Aspose.Words.Document("Anfangstext.docx")

    Dim builder As New DocumentBuilder(aw)
    builder.MoveToDocumentEnd()
    builder.InsertBreak(BreakType.SectionBreakContinuous)

    'load second document
    Dim EndeText As New Document("Endetext.docx")
    builder.MoveToDocumentEnd()

    'Add Endetext to Anfangstext
    builder.InsertDocument(EndeText, ImportFormatMode.UseDestinationStyles)
    aw.Save("c:\temp\newdoc.docx")

Attached are the two documents.

Textmerge.zip (1.7 MB)

@toschf71de

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-19726. 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-19726) have been fixed in this Aspose.Words for .NET 20.3 update and this Aspose.Words for Java 20.3 update.