Error when appending cloned documents

Hello,


We recently upgraded to Aspose.Words.dll version 14.9.0.0, and encountered this error when trying to append Document objects that had been produced by cloning.

srcContainer should belong to the source document.
at Aspose.Words.NodeImporter.(CompositeNode , CompositeNode , )
at Aspose.Words.NodeImporter.(Node , Boolean , )
at Aspose.Words.NodeImporter.(Node , DrawingML )
at Aspose.Words.NodeImporter.(Node , Node )
at Aspose.Words.NodeImporter.(Node , Boolean , )
at Aspose.Words.NodeImporter.(CompositeNode , CompositeNode , )
at Aspose.Words.NodeImporter.(Node , Boolean , )
at Aspose.Words.NodeImporter.(CompositeNode , CompositeNode , )
at Aspose.Words.NodeImporter.(Node , Boolean , )
at Aspose.Words.NodeImporter.(CompositeNode , CompositeNode , )
at Aspose.Words.NodeImporter.(Node , Boolean , )
at Aspose.Words.NodeImporter.(CompositeNode , CompositeNode , )
at Aspose.Words.Document.AppendDocument(Document srcDoc, ImportFormatMode importFormatMode)

A basic unit test to reproduce this error is:

[Test]
public void AppendClonedDocuments()
{
var documentA = new Document( “BadCloneForm.docx” ).Clone();
var documentB = new Document( “BadCloneForm.docx” ).Clone();
_AssertDoesNotThrow( () => documentA.AppendDocument( documentB, ImportFormatMode.KeepSourceFormatting ) );
}

private void _AssertDoesNotThrow( Action action )
{
Assert.DoesNotThrow( () =>
{
try
{
action();
}
catch( Exception ex )
{
Console.WriteLine( ex.Message );
Console.WriteLine( ex.StackTrace );
throw;
}
} );
}

The .docx file referenced is attached.

Thanks,
John Atwood

Hi John,

Thanks for your inquiry. I have tested the scenario and have managed to reproduce the same issue at my side. For the sake of correction, I have logged this problem in our issue tracking system as WORDSNET-10949. I have linked this forum thread to the same issue and you will be notified via this forum thread once this issue is resolved.

We apologize for your inconvenience.

Hi,

I just want to note that we have the same issue which breaks some code in our application.
While I can do a workaround (build the document each time from the template) I would like to know if there is known when this will be fixed.

Br
TK

Hi there,

Thanks for your inquiry. I
have verified the status of WORDSNET-10949 from our issue tracking system
and like to share with you that this issue has been planned for development.
Hopefully, the fix of this issue will be available in March/April 2015
release. Please note that this estimate is not final at the moment; I
will be sure to inform you via this forum thread as soon as your issues
are resolved.

We appreciate your patience.

I am also seeing this with some documents – is there any update on the time frame for the fix, or a suggested workaround. I can preprocess the document if necessary, is there a specific structure that can be avoided?

Hi there,

Thanks for your inquiry. I
have verified the status of WORDSNET-10949 from our issue tracking system. Currently, this issue is under development phase. Hopefully, the fix of this issue will be
available in March 2015 release. Please note that this estimate is not
final at the moment. We will update you via this forum thread once this issue is resolved.

We appreciate your patience.

Hi Tahir,


I’m also being affected by this bug, could you please confirm an ETA for this release?

Kind Regards,
Adam Nygate

Hi Adam,

Thanks for your inquiry. It is to inform you that this issue (WORDSNET-10949) has been resolved and its fix will be available in
Aspose.Words v15.3.0. Hopefully, the new version of Aspose.Words (v15.3.0) will be available at the end of this week or start of next week. We will inform you via this forum thread as soon as the
this release is published.

The issues you have found earlier (filed as WORDSNET-10949) have been fixed in this .NET update and this Java update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.