Unexpected DrawingML type

Hi,

After executing the code bellow I keep getting the following exception:
java.langIllegalArgumentException: Unexpected DrawingML type

Can you please check this out?

Thanks,
Zeljko

Code:

public void asposeTest() throws Exception {
Document doc = new Document("Test1.docx");
Run run = (Run) doc.getChild(NodeType.RUN, 0, true);
@SuppressWarnings("unchecked")
NodeCollection shapes = doc.getChildNodes(NodeType.SHAPE, true);
Shape shape1 = (Shape) shapes.get(0);
Shape shape2 = (Shape) shapes.get(1);
DocumentBuilder db = new DocumentBuilder(doc);
db.insertNode(run.deepClone(true));
db.insertNode(shape1.deepClone(true));
db.insertNode(shape2.deepClone(true));
doc = db.getDocument();
doc.save("Test2.docx");
}

Hi Zeljko,

Thanks for your inquiry. After an initial test with Aspose.Words for Java 15.10.0, we were unable to reproduce this issue on our end. We would suggest you please upgrade to the latest version of Aspose.Words. You can download it from the following link. Hope, this helps.

Download Aspose.Words for Java

Best regards,

Hi,

I tried running the above code, using the same document, with Aspose.Words for Java 15.10.0 and the problem occurred again. Not sure how this is possible? Apart from Aspose, I am also using Java 8 on Ubuntu 14.04. Since you are not able to reproduce the issue on your end, do you have any idea what else might cause this problem?
Also, please find attached the document containing the failure trace.

Thanks,
Zeljko

Hi Zeljko,

Thanks for your inquiry. We are working over your query and will get back to you soon.

Best regards,

Hi Zeljko,

Thanks for being patient. While using the latest version of Aspose.Words i.e. 15.11.0, we managed to reproduce this issue on our end. We have logged this issue in our bug tracking system. The ID of this issue is WORDSNET-12856. Your thread has been linked to this issue and you will be notified as soon as it is resolved. Sorry for the inconvenience.

Best regards,