'OpenXml SDK PowerPoint Sunburst chart
The Sunburst chart type was introduced in Office 2016 / 365, along with some other new chart types. I'm trying to work with the chart type in PowerPoint, but it can also be created in Excel, for example. (Excel provides the charting engine for all Office applications.)
Sunburst seems to be stored differently from other charts, the Productivity Tool doesn't seem to detect it normally and there seems to be an image representation of the chart instead of the actual chart data itself. The Productivity Tool shows no XML and the reflected code resembles the below
// Generates content of extendedPart1.
private void GenerateExtendedPart1Content(ExtendedPart extendedPart1)
{
System.IO.Stream data = GetBinaryDataStream(extendedPart1Data);
extendedPart1.FeedData(data);
data.Close();
}
which streams in binary information, for example
#region Binary Data
private string partData = "UEsDBBQABgAIAAAAIQBi7p1oXgEAAJAEAAATAAgCW0NvbnRlbnRfVHlwZXNdLnhtbCCiBAIooAACAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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bHMvd29ya2Jvb2sueG1sLnJlbHNQSwECLQAUAAYACAAAACEA++YwKnYDAADGDQAAGAAAAAAAAAAAAAAAAAA0DAAAeGwvd29ya3NoZWV0cy9zaGVldDEueG1sUEsBAi0AFAAGAAgAAAAhAMEXEL5OBwAAxiAAABMAAAAAAAAAAAAAAAAA4A8AAHhsL3RoZW1lL3RoZW1lMS54bWxQSwECLQAUAAYACAAAACEAeaGAbKQCAABSBgAADQAAAAAAAAAAAAAAAABfFwAAeGwvc3R5bGVzLnhtbFBLAQItABQABgAIAAAAIQCdyM0K/AAAAOwCAAAUAAAAAAAAAAAAAAAAAC4aAAB4bC9zaGFyZWRTdHJpbmdzLnhtbFBLAQItABQABgAIAAAAIQBU5rmyQQEAAGsCAAARAAAAAAAAAAAAAAAAAFwbAABkb2NQcm9wcy9jb3JlLnhtbFBLAQItABQABgAIAAAAIQBhSQkQiQEAABEDAAAQAAAAAAAAAAAAAAAAANQdAABkb2NQcm9wcy9hcHAueG1sUEsFBgAAAAAKAAoAgAIAAJMgAAAAAA==";
Is it possibly to generate a Sunburst Chart in PowerPoint using OpenXML SDK in C#?
Solution 1:[1]
Adding charts to a presentation using Open XML SDK is very time consuming. If you were to use Aspose.Slides for .NET, you would add a Sunburst chart like this:
using var presentation = new Presentation();
// Add an empty Sunburst chart to the first slide.
var chart = presentation.Slides[0].Shapes.AddChart(ChartType.Sunburst, 20, 20, 500, 400);
chart.ChartData.Categories.Clear();
chart.ChartData.Series.Clear();
var wb = chart.ChartData.ChartDataWorkbook;
wb.Clear(0);
// Branch 1:
var leaf = chart.ChartData.Categories.Add(wb.GetCell(0, "C1", "Leaf1"));
leaf.GroupingLevels.SetGroupingItem(1, "Stem1");
leaf.GroupingLevels.SetGroupingItem(2, "Branch1");
chart.ChartData.Categories.Add(wb.GetCell(0, "C2", "Leaf2"));
leaf = chart.ChartData.Categories.Add(wb.GetCell(0, "C3", "Leaf3"));
leaf.GroupingLevels.SetGroupingItem(1, "Stem2");
chart.ChartData.Categories.Add(wb.GetCell(0, "C4", "Leaf4"));
// Branch 2:
leaf = chart.ChartData.Categories.Add(wb.GetCell(0, "C5", "Leaf5"));
leaf.GroupingLevels.SetGroupingItem(1, "Stem3");
leaf.GroupingLevels.SetGroupingItem(2, "Branch2");
chart.ChartData.Categories.Add(wb.GetCell(0, "C6", "Leaf6"));
leaf = chart.ChartData.Categories.Add(wb.GetCell(0, "C7", "Leaf7"));
leaf.GroupingLevels.SetGroupingItem(1, "Stem4");
chart.ChartData.Categories.Add(wb.GetCell(0, "C8", "Leaf8"));
var series = chart.ChartData.Series.Add(ChartType.Sunburst);
series.Labels.DefaultDataLabelFormat.ShowCategoryName = true;
series.DataPoints.AddDataPointForSunburstSeries(wb.GetCell(0, "D1", 4));
series.DataPoints.AddDataPointForSunburstSeries(wb.GetCell(0, "D2", 5));
series.DataPoints.AddDataPointForSunburstSeries(wb.GetCell(0, "D3", 3));
series.DataPoints.AddDataPointForSunburstSeries(wb.GetCell(0, "D4", 6));
series.DataPoints.AddDataPointForSunburstSeries(wb.GetCell(0, "D5", 9));
series.DataPoints.AddDataPointForSunburstSeries(wb.GetCell(0, "D6", 9));
series.DataPoints.AddDataPointForSunburstSeries(wb.GetCell(0, "D7", 4));
series.DataPoints.AddDataPointForSunburstSeries(wb.GetCell(0, "D8", 3));
presentation.Save("Sunburst.pptx", SaveFormat.Pptx);
Result:
This is a paid library, but you can get a temporary license to evaluate all features. I work as a Support Developer at Aspose.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | Andrey Potapov |