How to copy shape?

I have Aspose.Slides and would like to know how to copy shape or autoshape. I am working with pptx file. Thanks

Hello Dear,

Thanks for your interest in Aspose.Slides.

I am sorry to inform you that the requested feature is currently not supported in Aspose.Slides for .NET. However, we have already logged a new feature request as SLIDESNET-18109 in our issue tracking system to support it. You will be notified via this forum thread once this feature is available.

We are sorry for the inconvenience.

Thanks Tahir.
Can I at least copy the properties from one AutoShapeEx that I have as a template to newly created AutoShapeEx? What is the best way to do it? do you have any examples? This got to be a common operation.

Thanks.

Hello dear,

I regret to share with you that there is no way to copy properties of AutoShapeEx. The only way to do this is, you can set properties of one AutoShapeEx to another shape. Please see the following code snippet. Please find the source presentation file in attachment as well.

PresentationEx srcPres = new PresentationEx(“d:\AutoShapeEx.pptx”);
//Get the shape which is already exists in slide
ShapeEx shp = srcPres.Slides[0].Shapes[0];
//Create a new shape
int shpId = srcPres.Slides[0].Shapes.AddAutoShape(ShapeTypeEx.Rectangle, 10, 10, 100, 100);

//Set properties of new shape form the shape which is already exists in sldie
srcPres.Slides[0].Shapes[shpId].FillFormat.FillType = shp.FillFormat.FillType;

srcPres.Slides[0].Shapes[shpId].FillFormat.SolidFillColor.Color = shp.FillFormat.SolidFillColor.Color;

srcPres.Slides[0].Shapes[shpId].Width = shp.Width;
srcPres.Slides[0].Shapes[shpId].Height = shp.Height;

srcPres.Save(“d:\outPut.pptx”, Aspose.Slides.Export.SaveFormat.Pptx);

Any updates on this issue?

Hi,

I have verified from our issue tracking system and regret to share that the requested support is currently unavailable in Aspose.Slides. The said feature support will be available in Aspose.Slides after release of unified API. The said API will be available during Q1 of 2014. The mentioned feature support will be available in unified API. We will share the notification with you once the feature will be available.

Many Thanks,

The issues you have found earlier (filed as SLIDESNET-18109) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.
(8)