Error on Presentation.Open

Hi

I am getting the following error on opening the presentation file:

Error:

"An XML error has occurred"

Stack Trace:

"

   at Syncfusion.OfficeChart.Implementation.XmlSerialization.Charts.ChartParser.ParseDataPoint(XmlReader reader, ChartSerieImpl series, RelationCollection relations)

   at Syncfusion.OfficeChart.Implementation.XmlSerialization.Charts.ChartExParser.ParseChartExSeries(XmlReader reader, ChartImpl chart, RelationCollection relations, Excel2007Parser excel2007Parser, Int32& secondaryAxisId)

   at Syncfusion.OfficeChart.Implementation.XmlSerialization.Charts.ChartExParser.ParsePlotAreaRegion(XmlReader reader, ChartImpl chart, RelationCollection relations, Excel2007Parser excel2007Parser, Int32& secondaryAxisId)

   at Syncfusion.OfficeChart.Implementation.XmlSerialization.Charts.ChartExParser.ParseChartExPlotArea(XmlReader reader, ChartImpl chart, RelationCollection relations, Excel2007Parser excel2007Parser)

   at Syncfusion.OfficeChart.Implementation.XmlSerialization.Charts.ChartExParser.ParseChartExElement(XmlReader reader, ChartImpl chart, RelationCollection relations)

   at Syncfusion.OfficeChart.Implementation.XmlSerialization.Charts.ChartExParser.ParseChartEx(XmlReader reader, ChartImpl chart, RelationCollection relations)

   at Syncfusion.Presentation.FileDataHolder.ParseChartData(PresentationChart chart, String chartPath)

   at Syncfusion.Presentation.FileDataHolder.ParseChart(PresentationChart chart)

   at Syncfusion.Presentation.Parser.CheckGraphicData(Stream stream, Shapes shapeCollection)

   at Syncfusion.Presentation.Parser.ParseShapeTree(XmlReader reader, Shapes shapeCollection)

   at Syncfusion.Presentation.Parser.ParseCommonSilde(XmlReader reader, BaseSlide slide)

   at Syncfusion.Presentation.Parser.ParseSlide(XmlReader reader, Slide slide)

   at Syncfusion.Presentation.FileDataHolder.ParseSlide(Slide slide, String slidePath)

   at Syncfusion.Presentation.FileDataHolder.ParseSlides()

   at Syncfusion.Presentation.FileDataHolder.Read()

   at Syncfusion.Presentation.FileDataHolder.ParseDocument()

   at Syncfusion.Presentation.Presentation.ParseDocument(Stream fileStream)

   at Syncfusion.Presentation.Presentation.OpenAsStream(Stream stream, String password, String extension)

   at Syncfusion.Presentation.Presentation.Open(Stream fileStream)

   at Revuze.Pro.Reports.Services.ReportsService.GenerateStarRatingPPT(OverviewSlideModel overviewSlideModel) in C:\Users\moran\source\repos\Pro\revuze.pro.reports\Revuze.Pro.Reports\Services\ReportsService.cs:line 32

"

line of code

"IPresentation pptxDoc = Presentation.Open(new FileStream(_generalTempaltePath, FileMode.Open))"

I get the error on the file: "Revuze_Graphs 2_v2.pptx"

the file "Revuze_Graphs 4_v1.pptx" is working correctly, I have attached the files to the Thread

Can you help me understand what's the issue? 


Attachment: Tamplates_43b4e1ff.zip

22 Replies 1 reply marked as answer


MM Moran Monovich December 20, 2021 12:17 PM UTC

Hi

Thanks for your fast response. After I get the error message, nothing was created. 



LB Lokesh Baskar Syncfusion Team December 21, 2021 05:51 AM UTC

Hi Moran,

Could you please share your end requirement such as whether you are converting PPTX document to PDF or resaving the document as pptx or converting the pptx file to image. So that we will check any other preservation after our validation.

Regards,
Lokesh B 



MM Moran Monovich December 21, 2021 06:32 AM UTC

Hi

The end requirement is to fill the existing PPT with our own website data. the idea is to use the PPT I sent you as a base template and to fill it with relevant data each time the client press download.



LB Lokesh Baskar Syncfusion Team December 21, 2021 09:06 AM UTC

Hi Moran,

Thank you for sharing the details. Currently we are validating and share the details on 22nd December 2021.

Regards,
Lokesh B 



LB Lokesh Baskar Syncfusion Team December 22, 2021 01:53 PM UTC

Hi Moran,

We have confirmed that the mentioned “Exception throws while opening the presentation document with Treemap chart” is issue and we have logged a defect report. We will include the fix for this defect in our weekly NuGet release which is estimated to be available on 11th January 2022.  

The status of this bug report can be tracked through the below link: 
https://www.syncfusion.com/feedback/31410/exception-throws-while-opening-the-presentation-document-with-treemap-chart
   
If you are using any other Essential Studio version then kindly let us know the currently installed version, so that we can provide patch in that version based on our SLA policy.  

 
Note: We don’t have support for Treemap in chart to image conversion. Already we have logged as a feature for that issue and we don’t have any immediate plan to implement this feature.
https://www.syncfusion.com/feedback/2653/render-treemap-chart-in-chart-to-image-conversion

 
Regards,
Lokesh B
 



MM Moran Monovich December 22, 2021 02:04 PM UTC

Thanks.

Once I remove the treemap chart from the last slide, I get an error about "DataLabelRange". Does  Syncfusion support data labels? 



LB Lokesh Baskar Syncfusion Team December 23, 2021 07:24 AM UTC

Hi Moran,

We have tried to reproduce the issue after removed of treemap chart, but we don’t get any error while opening the document. For your reference, we have attached the document which we used to reproduce the reported issue and it can be downloaded from the below link:
https://www.syncfusion.com/downloads/support/forum/171336/pp/Revuze_Graphs_2_v2_RemovedTreeMapChart511611637.pptx 


 
Could you please share that issue reproducible document at your end. This will be more helpful to reproduce the same issue at our end. Thereby, we will proceed further on the reported issue and provide you with the appropriate solution at the earliest.


 
Regards,
Lokesh B  




MM Moran Monovich January 18, 2022 10:08 AM UTC

Hi

I tried to render the treemap chart using the latest version on NuGet - 19.4.0.43, but the chart won't render. 

I am not getting any error messages or exceptions, only the chart area in the slide won't render. I attached the ppt template that I work with.



Attachment: Product_360_7d7c0623.zip


LB Lokesh Baskar Syncfusion Team January 19, 2022 07:32 AM UTC

Hi Moran,

Currently, we don’t have support for treemap chart in PPTX to PDF and PPTX to image conversion. We have already logged this requirement as feature request in our database. We don’t have any immediate plans to implement this feature. At the planning stage for every release cycle, we review all open features. We will let you know when this feature is implemented.

You can track the status of this feature from the below link:
https://www.syncfusion.com/feedback/2653/render-treemap-chart-in-chart-to-image-conversion

Regards,
Lokesh  B  



LB Lokesh Baskar Syncfusion Team January 31, 2022 01:31 PM UTC

Hi Moran,

We have included the fix for the reported issue with “Exception throws while opening the presentation document with Treemap char" in our 2021 Volume 4 SP release v19.4.0.48.
We are glad to announce that our Essential Studio 2021 Volume 4 SP release v19.4.0.48 is rolled out and is available for download under the following link. 
https://www.syncfusion.com/forums/172430/essential-studio-2021-volume-4-service-pack-release-v19-4-0-48-is-available-for-download

The status of this bug task can be tracked through the following link:
https://www.syncfusion.com/feedback/31410/exception-throws-while-opening-the-presentation-document-with-treemap-chart

We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.

Regards,
Lokesh B
 



MM Moran Monovich February 22, 2022 02:27 PM UTC

Hi

Can you give me an example for creating a treemap chart? one that I can define the colors based on the range of the values and the data label is in the middle? 




LB Lokesh Baskar Syncfusion Team February 23, 2022 03:04 PM UTC

Hi Moran,

From the given details we have found that your requirement is to create a tree map chart and change the color of the datapoints. We have prepared the sample application to achieve your requirement. Please find the sample application from the below link.
 



MM Moran Monovich February 27, 2022 08:49 PM UTC

Thank you, I am working on your example and was wondering how can I get the data but not from the Xls file. Since I get the data for our front end.

I am having an issue accessing the series from the code below, I get an exception when I try to get and change the series properties -> the code is marked with an underline.

var topicMapChart = slide.Charts.AddChart(120, 50, 1450, 710);
_pptHelperService.UpdateChart(topicMapChart, productVSCategoryModel.product_vs_category_chart);
topicMapChart.ChartType = OfficeChartType.TreeMap;
topicMapChart.IsSeriesInRows = false;
var series = topicMapChart.Series[0];
series.DataPoints.DefaultDataPoint.DataLabels.IsCategoryName = true;
series.SerieFormat.TreeMapLabelOption = TreeMapLabelOption.None;
topicMapChart.HasLegend = false;


LB Lokesh Baskar Syncfusion Team February 28, 2022 03:05 PM UTC

Hi Moran,

From the given screenshot the reported issue occurs due to series is set properly. We have modified the the sample application to achieve your requirement. Please find the sample application from the below link.
  



MM Moran Monovich March 1, 2022 06:49 PM UTC

Thank for the sample

I found that there is a topic missing in the chart example you sent me. I marked it in the screenshots below

I didn't understand why there's a calculation for: 

serie1.DataPoints[i - serie1.Values.FirstRow]

Can't I just iterate on the index itself? 



LB Lokesh Baskar Syncfusion Team March 2, 2022 04:25 PM UTC

Hi Moran,

Regarding I found that there is a topic missing in the chart example you sent me.
 
On further checking the problem we suspect that it to be a defect. We will validate this issue and share the details on 4th March 2022.

Regarding Can't I just iterate on the index itself?
 
Yes, we can also iterate on the index itself.

Regards,
Lokesh B
   



MM Moran Monovich March 3, 2022 03:16 PM UTC

Thanks for your response.

Can you help me with the data label? I want to place them like in this image



MR Manikandan Ravichandran Syncfusion Team March 4, 2022 12:43 PM UTC

Hi Moran,

We have confirmed the reported issue with “Last data label is incorrect in the Presentation document for tree map chart” as a defect in our end. We will include the fix for this issue in our upcoming weekly NuGet release on 29th March 2022

Please use the below feedback link to track the status of the reported bug.
https://www.syncfusion.com/feedback/33187/last-data-label-is-incorrect-in-the-presentation-document-for-treemap-chart

Reg – Data label query:
From the given details, we have suspect that your requirement is to add the data label in the center of the each series of the chart. For this requirement, please refer the below code example. 
chart.Series[0].DataPoints[0].DataLabels.Position = OfficeDataLabelPosition.Center; 

Note: Inclusion of this solution in the weekly release may change due to other factors including but not limited to QA checks and works reprioritization.

Regards,
Manikandan Ravichandran
 



LB Lokesh Baskar Syncfusion Team March 29, 2022 12:57 PM UTC

Hi Moran,

We have fixed the reported “Last data label is incorrect in the Presentation document for tree map chart” issue at our end. Since our 2022 volume 1 main release is expected to be rolled out this week. So there will be no weekly release this week.

W
e have prepared the custom patch NuGet for the reported issue in v19.4.0.56. Please find the custom patch NuGet form the below link:
https://www.syncfusion.com/downloads/support/directtrac/general/ze/syncfusion.officechart.net.core.19.4.0.562091294266

We will include the fix for the reported issue in our upcoming weekly NuGet release once our 2022 Volume 1 is rolled out which we excepted on the first week of April 2022 tentatively.

The status of this bug report can be tracked through the below link:  

https://www.syncfusion.com/feedback/33187/last-data-label-is-incorrect-in-the-presentation-document-for-treemap-chart


Regards, 

Lokesh B 


Marked as answer

MR Manikandan Ravichandran Syncfusion Team April 12, 2022 03:46 PM UTC

Hi Moran,

As promised earlier, we have included the fix for the reported issue with “Last data label is incorrect in the Presentation document for tree map chart" in our latest weekly NuGet release (v20.1.0.48).

Please use the below link to download our latest weekly NuGet:
https://www.nuget.org/packages/Syncfusion.Presentation.Net.Core/20.1.0.48

The status of this bug task can be tracked through the below link:
https://www.syncfusion.com/feedback/33187/last-data-label-is-incorrect-in-the-presentation-document-for-treemap-chart

Note: We will include this fix in our 2022 Volume 1 SP release which will be available in mid of May 2022.

Regards,
Manikandan Ravichandran


Loader.
Up arrow icon