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

Free Support Forum - aspose.com

Chart legends - custom position

Version: 14.9.0

I have been attempting to position the legend in the top left corner. Here is the code:

public static void main(String[] args) {
final Presentation pres = new Presentation();
final IChart c = pres.getSlides()
0, 0, 500, 500);
final ILegend legend = c.getLegend();
// Want to move to top left
“x=%f, y=%f, w=%f, h=%f”,
pres.save(“D:/test.pptx”, SaveFormat.Pptx);

The console out put is:

x=0.000000, y=0.000000, w=NaN, h=NaN

The legend does not move. Any advice?

Result of code is attached.

Hi Shaun,

I have observed the requirement shared and like to share that at present Aspose.Slides offers to set the position by using predetermined positions in enumerators. The custom size and position for legends is unavailable in Aspose.Slides. I have created an issue with ID SLIDESJAVA-34642 in our issue tracking system to further investigate the possibility of implementing the requested support. This thread has been linked with the issue so that you may be automatically notified once the support will be available.

We are sorry for your inconvenience,

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

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