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

Free Support Forum - aspose.com

Embedded OLE object


I am able to extract the embedded excel file from the document using Aspose.Words as follows. But I am not able to figure out to embed the changed file back into the document. Can anyone help?

Document doc = new Document("C:\sample.docx");
NodeCollection shapes = doc.GetChildNodes(NodeType.Shape, true);
foreach (Shape shape in shapes)
// Ignore if not OLE
if (shape.ShapeType != Drawing.ShapeType.OleObject)

MemoryStream ms = new MemoryStream();

// process embedde file

// save it back to word file



Hi Mohammed,

Thanks for your inquiry.
Unfortunately, inserting new OLE objects into Word documents and updating existing OLE objects is not supported at the moment.

We had already logged this feature request as WORDSNET-1206 in our issue tracking system. I have linked this forum thread to the same feature and you will be notified via this forum thread once this feature is available.

We apologize for your inconvenience.

Thanks Tahir.



Hi Mohammed,

Please feel free to ask if you have any question about Aspose.Words, we will be happy to help you.

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

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