Hi,
I am not able to set the style to the data labels and setting the color to the slices(series) of the Pai chart.
In line/column chart, if I am not setting the color/marker to the series, all the series are coming as a single color/marker.
Please find the attached sample application and the image for more details.
Thanks,
Laxmikanta
Hi Laxmikanta,
Hi Mudassir,
Do we have any option to set the chart.ChartArea font style in MSO chart and setting the Show Leader Lines of data labels?
Thanks,
Laxmikanta
Hi Laxmikanta,
I like to share that currently support adding and showing/hiding the leader lines for Pie chart is unavailable in Aspose.Slides. An issue with ID SLIDESNET-33622 has already been created in our issue tracking system to provide the feature support. This thread has been linked with the issue so that you may be automatically notified once the issue will be resolved.
However, for your requirements related to chart area font styles, can you please elaborate in detail with example so that I may help you better in this regard.
We are sorry for your inconvenience,
Please find the image for more details?
Hi Laxmikanta,
Thanks for sharing the image. From image, I have perceived that you are trying to set the font related properties for labels of the Pie charts. I like to sahre that you may have probably share this requirement in your very first post of this thread link. You may use the sample code and add it accordingly in your sample code to fulfill the requirements for the time being until the issue is resolved.
Hi Mudassir,
Thanks for your response. Sorry in the last image sent by me, I focused to data labels. But actually I was asking, how to set the font properties to the chart area not the data labels. If I am able to set the font properties to the chart area, than each object inside the chart area will have same font style.
Thanks,
Laxmikanta
Hi Laxmikanta,
Hi Mudassir,
If presently the feature or property for getting chart area is available in Aspose.Slides for .NET. Please provide me the code snippet.
And how one can set the font related properties for all entities independently? Please provide me the code snippet for this also.
Thanks,
Laxmikanta
Hi Laxmikanta,
public static void MangChartProperties(){PresentationEx pres = new PresentationEx();SlideEx slide = pres.Slides[0];ChartEx chart = slide.Shapes.AddChart(ChartTypeEx.ClusteredColumn, 50, 50, 500, 400);TextFrameEx txt = chart.CategoryAxis.TextProperties;txt.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontBold = NullableBool.True;txt.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontHeight = 20;txt.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontItalic = NullableBool.True;txt.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FillFormat.FillType = FillTypeEx.Solid; ;txt.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FillFormat.SolidFillColor.Color = Color.Blue;TextFrameEx txt2 = chart.ValueAxis.TextProperties;txt2.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontBold = NullableBool.True;txt2.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontHeight = 20;txt2.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontItalic = NullableBool.True;txt2.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FillFormat.FillType = FillTypeEx.Solid; ;txt2.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FillFormat.SolidFillColor.Color = Color.Blue;TextFrameEx txt3 = chart.Legend.TextProperties;txt3.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontBold = NullableBool.True;txt3.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontHeight = 20;txt3.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontItalic = NullableBool.True;txt3.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FillFormat.FillType = FillTypeEx.Solid; ;txt3.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FillFormat.SolidFillColor.Color = Color.Blue;pres.Write(“D:\Aspose Data\AxisValue.pptx”);}
Hi Laxmikanta,
I like to share that feature for setting the pie chart color has been added in Aspose.Slides for .NET 6.7.0. Please visit this documentation link for your kind reference. We will share the notification with you once Aspose.Slides for .NET 6.7.0 will be made available by tonight.
Many Thanks,
The issues you have found earlier (filed as SLIDESNET-33589) have been fixed in this update.
This message was posted using Notification2Forum from Downloads module by aspose.notifier.
(1)
May I know the status of the issue with ID SLIDESNET-33742, SLIDESNET-33620 and SLIDESNET-33622.
Hi Laxmikanta,
Hi Laxmikanta,
public static void SetPieDefaultLabels(){PresentationEx pres = new PresentationEx();SlideEx sld = pres.Slides[0];Aspose.Slides.Pptx.ChartEx chart = sld.Shapes.AddChart(ChartTypeEx.Pie3D, 100, 100, 400, 400);ChartDataCellFactory fact = chart.ChartData.ChartDataCellFactory;chart.ChartData.Series.Clear();chart.ChartData.Categories.Clear();chart.ChartData.Categories.Add(fact.GetCell(0, 1, 0, “First Qtr”));chart.ChartData.Categories.Add(fact.GetCell(0, 2, 0, “2nd Qtr”));chart.ChartData.Categories.Add(fact.GetCell(0, 3, 0, “3rd Qtr”));chart.ChartData.Series.Add(fact.GetCell(0, 0, 1, “Series 1”), chart.Type);ChartSeriesEx series = chart.ChartData.Series[0];series.Values.Add(fact.GetCell(0, 1, 1, 20000));series.Values.Add(fact.GetCell(0, 2, 1, 50000));series.Values.Add(fact.GetCell(0, 3, 1, 30000));series.Labels.ShowValue = true;series.Labels.ShowPercentage = true;series.Labels.ShowLegendKey = false;// chart.ChartData.Series.Add(fact.GetCell(0, 0, 1, “Series 1”), chart.Type);series.Labels.TextProperties.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FontBold = NullableBool.True;series.Labels.TextProperties.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FillFormat.FillType = FillTypeEx.Solid;series.Labels.TextProperties.Paragraphs[0].ParagraphFormat.DefaultPortionFormat.FillFormat.SolidFillColor.Color = Color.Blue;pres.Write(@“D:\Aspose Data\PieChart.pptx”);}
The issues you have found earlier (filed as SLIDESNET-33620) have been fixed in this update.
This message was posted using Notification2Forum from Downloads module by aspose.notifier.
How to set the font property to a data labels of a MSO Pie chart?
Please look at the attached image for more info.
Thanks,
Laxmikanta
Hi Laxmikanta,
The issues you have found earlier (filed as SLIDESNET-33622) have been fixed in this update.
This message was posted using Notification2Forum from Downloads module by aspose.notifier.
Hi,
Kindly share the code snippet for the SLIDESNET-33622(Showing/hiding the leader lines for Pie chart).
Thanks,
Laxmikanta