RadarChartView Class
Defines the view settings for a radar chart.
Namespace: DevExpress.Docs.Office
Assembly: DevExpress.Docs.Core.v26.1.dll
NuGet Package: DevExpress.Docs.Core
Declaration
Remarks
For additional information about series and views, refer to the following help topic: Series and Views.
Example
The following code snippet creates a radar series and configures its arguments and values:
using DevExpress.Docs.Office;
using DevExpress.Docs.Presentation;
using System.Drawing;
namespace PresentationApiSample;
public class Program {
public static async Task Main(string[] _) {
// Create a presentation.
Presentation presentation = new Presentation();
// Reset the slide collection.
presentation.Slides.Clear();
// Add a blank slide.
Slide slide = new Slide(SlideLayoutType.Blank);
presentation.Slides.Add(slide);
// Insert a chart on the slide.
Chart chart = new Chart();
slide.Shapes.Add(chart);
// Set chart size to match the slide.
chart.Width = presentation.SlideSize.Width;
chart.Height = presentation.SlideSize.Height;
// Create the first radar series.
RadarSeries series1 = new RadarSeries();
// Assign arguments and values to the first series.
series1.Arguments = new ChartStringData(new string[] { "A", "B", "C", "D", "E" });
series1.Values = new ChartNumericData(new double[] { 10, 20, 30, 40, 50 });
// Set a translucent fill for the first series.
series1.Properties = new ChartElement { Fill = new SolidFill(Color.FromArgb(150, Color.MistyRose)) };
chart.Series.Add(series1);
// Create the second radar series.
RadarSeries series2 = new RadarSeries();
// Assign arguments and values to the second series.
series2.Arguments = new ChartStringData(new string[] { "A", "B", "C", "D", "E" });
series2.Values = new ChartNumericData(new double[] { 60, 30, 40, 50, 20 });
// Set a translucent fill for the second series.
series2.Properties = new ChartElement { Fill = new SolidFill(Color.FromArgb(100, Color.RoyalBlue)) };
chart.Series.Add(series2);
// Apply the filled style to the radar chart.
RadarChartView view = chart.Views[0] as RadarChartView;
view.Style = RadarChartStyle.Filled;
// Hide the chart legend.
chart.Legend = null;
// Save the result to a file.
var outputPath = @"D:\presentation.pptx";
using FileStream outputStream = new(outputPath, FileMode.Create, FileAccess.Write, FileShare.None);
presentation.SaveDocument(outputStream);
}
}
Implements
Inheritance
See Also