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

Free Support Forum - aspose.com

Border for Charts in Powerpoint export


I’m using aspose slides JAVA to export PPT along with charts. I wanted to add border to the chart. But could not find any option to do so. Any leads on how to add border for charts will be highly helpful. Thanks in advance.

Hi Vasanth,

I have observed your requirements and like to share that chart is a shape in PowerPoint slides. You can use the same properties as used for generic Shape object to set the chart borders. Please try using the following sample code on your end to serve the purpose. I hope this will be helpful. Please share if I may help you further in this regard.

Presentation pres=new Presentation();
ISlide slide=pres.getSlides().get_Item(0);

IChart chart=slide.getShapes().addChart(ChartType.ClusteredColumn, 50,50,300,300);

ILineFormat chartLineFormat= chart.getLineFormat();


pres.save(“D:\Aspose Data\ChartBorder.pptx”,SaveFormat.Pptx);

Many Thanks,

Hi Mudassir,

Many thanks. It worked like a charm. Thanks for the sample attachment as well.

Hi Vasanth,

It’s good to know that things are working on your end. Please share, if I may help you further in this regard.

Many Thanks,