Is it possible to create OLE_OBJECTS programmatically in Aspose.Words.
Shape shape = new Shape(doc, ShapeType.OLE_OBJECT);
I tried this but get that exception:
Exception in thread “main” java.lang.UnsupportedOperationException: Cannot create shapes of this type.
at com.aspose.words.Shape.(Unknown Source)
I am trying to include prexisting Excel charts in my Word Document. Is there any way to do that?
Thanks for your interest in Aspose products.
Well, inserting new OLE objects into a Word Document and updating existing OLE objects is not supported at the moment. Inserting an OLE object usually requires the host application and probably cannot be done by Aspose.Words.
What is supported is preserving OLE objects in documents. That is if you open a Microsoft Word document and then save it (possibly in another Microsoft Word format) then OLE objects are preserved. You can also access objects programmatically, extract their data and preview image. However, 'creating new OLE objects' is not supported.
I have linked your request to the appropriate new feature (WORDSNET-1206) in our issue tracking system. You will be notified as soon as this feature is supported. We apologize for any inconvenience.
Secondly, currently there is no way to copy chart from Excel to Word as real chart. At the moment you can convert Excel chart to image using Aspose.Cells and then insert this image into Word document using Aspose.Words. In the future we will consider adding a public API that allows creating charts from scratch in Word documents (WORDSNET-4617). This should allow you to recreate chart from Excel in Word document.
This message was posted using Notification2Forum from Downloads module by aspose.notifier.