Free Support Forum - aspose.com

Presentation crashes on saving when adding custom legends

Dear,


I’m using aspose.slide version 7.1 to create a .pptx presentation. I am adding a ClustoredColumn chart to my presentation. When I add custom legends to the columns, open the presentation and try to save it, it crashes. Please find bellow the code I am using:
{
SlideEx sld = pres.Slides[0];
Aspose.Slides.Pptx.ChartEx chart = sld.Shapes.AddChart(ChartTypeEx.ClusteredColumn, 100, 100, 400, 400);
chart.ChartTitle.Text.Text = “Sample Title”;
chart.ChartTitle.Text.CenterText = true;
chart.ChartTitle.Height = 20;
chart.HasTitle = true;
ChartDataCellFactory fact = chart.ChartData.ChartDataCellFactory;
chart.ChartData.Categories.Add(fact.GetCell(0, 1, 0, “C1”));
int Id = chart.ChartData.Series.Add(fact.GetCell(0, 0, 1, “Series 1”), chart.Type);

ChartSeriesEx series = chart.ChartData.Series[Id];
series.Labels.ShowLeaderLines = true;
int defaultWorksheetIndex = 0;
series.Values.Add(fact.GetCell(defaultWorksheetIndex, 1, 1, 20));
series.Values.Add(fact.GetCell(defaultWorksheetIndex, 2, 1, 50));
series.Values.Add(fact.GetCell(defaultWorksheetIndex, 3, 1, 30));
for (int i = 0; i < 3; i++)
{
DataLabelEx lbl = new DataLabelEx(series);
lbl.TextFrame.Text = (i*10).ToString(); //<-- this line is causing the problem
lbl.Id = i;
series.Labels.Add(lbl);
}
}

When I run this code, I am able to generate the presentation and I can open it successfully. But if I try to change anything in the presentation and try to save, it crashes.

Thank you in advance,
Sami Simon

Hi Sami Simon,


I have worked over the scenario shared by you and have been able to observe the issue specified. An issue with ID SLIDESNET-33996 has been created in our issue tracking system to further investigate and resolve the issue. This thread has been linked with the issue so that you may be automatically notified once the issue will be resolved.

We are sorry for your inconvenience,

Dear,


Thank you so much for your reply. Being able to set custom legends for column charts and being able to change and save the presentation afterwards is very urgent to our business since the client asked for it. So could you please give me a time estimate on when this issue will be fixes since I need to communicate that with the client.

Thank you for your understanding,
Sami Simon

Hi Sami Simon,


I like to share that the issue shared has just been shared and I have requested our development team to investigate the issue earlier if possible. I will share the further feedback with you as soon as the issue will be resolved.

Many Thanks,

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


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