WinUI

Code Examples Upgrade Guide User Guide Demos Support Forums Download
  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class CartesianSeries

    Show / Hide Table of Contents

    Class CartesianSeries

    Inheritance
    System.Object
    ChartSeries
    DataMarkerSeries
    CartesianSeries
    XyDataSeries
    Implements
    ISupportAxes
    Inherited Members
    DataMarkerSeries.ShowDataLabelsProperty
    DataMarkerSeries.ShowDataLabels
    ChartSeries.SpacingProperty
    ChartSeries.TooltipTemplateProperty
    ChartSeries.EnableTooltipProperty
    ChartSeries.ListenPropertyChangeProperty
    ChartSeries.IsSeriesVisibleProperty
    ChartSeries.XBindingPathProperty
    ChartSeries.ItemsSourceProperty
    ChartSeries.TrackballLabelTemplateProperty
    ChartSeries.FillProperty
    ChartSeries.LabelProperty
    ChartSeries.LegendIconProperty
    ChartSeries.LegendIconTemplateProperty
    ChartSeries.IsVisibleOnLegendProperty
    ChartSeries.EnableAnimationProperty
    ChartSeries.AnimationDurationProperty
    ChartSeries.PaletteBrushesProperty
    ChartSeries.StrokeProperty
    ChartSeries.StrokeThicknessProperty
    ChartSeries.SuspendNotification()
    ChartSeries.ResumeNotification()
    ChartSeries.OnPointerPressed(PointerRoutedEventArgs)
    ChartSeries.OnPointerMoved(PointerRoutedEventArgs)
    ChartSeries.OnTapped(TappedRoutedEventArgs)
    ChartSeries.OnPointerExited(PointerRoutedEventArgs)
    ChartSeries.OnPointerReleased(PointerRoutedEventArgs)
    ChartSeries.PaletteBrushes
    ChartSeries.TooltipTemplate
    ChartSeries.EnableTooltip
    ChartSeries.ListenPropertyChange
    ChartSeries.IsSeriesVisible
    ChartSeries.ItemsSource
    ChartSeries.TrackballLabelTemplate
    ChartSeries.Fill
    ChartSeries.Label
    ChartSeries.LegendIcon
    ChartSeries.LegendIconTemplate
    ChartSeries.IsVisibleOnLegend
    ChartSeries.XBindingPath
    ChartSeries.EnableAnimation
    ChartSeries.AnimationDuration
    ChartSeries.StrokeThickness
    ChartSeries.Chart
    ChartSeries.Stroke
    ChartSeries.PropertyChanged
    Namespace: Syncfusion.UI.Xaml.Charts
    Assembly: Syncfusion.Chart.WinUI.dll
    Syntax
    public abstract class CartesianSeries : DataMarkerSeries, ISupportAxes

    Constructors

    CartesianSeries()

    Called when instance created for CartesianSeries.

    Declaration
    public CartesianSeries()

    Fields

    DataLabelSettingsProperty

    The DependencyProperty for CartesianDataLabelSettings property.

    Declaration
    public static readonly DependencyProperty DataLabelSettingsProperty
    Field Value
    Type Description
    Microsoft.UI.Xaml.DependencyProperty

    ShowTrackballInfoProperty

    The DependencyProperty for ShowTrackballInfo property.

    Declaration
    public static readonly DependencyProperty ShowTrackballInfoProperty
    Field Value
    Type Description
    Microsoft.UI.Xaml.DependencyProperty

    XAxisNameProperty

    Declaration
    public static readonly DependencyProperty XAxisNameProperty
    Field Value
    Type Description
    Microsoft.UI.Xaml.DependencyProperty

    YAxisNameProperty

    Declaration
    public static readonly DependencyProperty YAxisNameProperty
    Field Value
    Type Description
    Microsoft.UI.Xaml.DependencyProperty

    Properties

    DataLabelSettings

    Gets or sets a value to customize the appearance of the displaying data labels in the cartesian series.

    Declaration
    public CartesianDataLabelSettings DataLabelSettings { get; set; }
    Property Value
    Type Description
    CartesianDataLabelSettings

    It takes the CartesianDataLabelSettings.

    Remarks

    This allows us to change the look of the displaying labels' content, shapes, and connector lines at the data point.

    Examples
    • Xaml
    • C#
        <chart:SfCartesianChart>
    
        <!-- ... Eliminated for simplicity-->
    
             <chart:AreaSeries ItemsSource="{Binding Data}"
                               XBindingPath="XValue"
                               YBindingPath="YValue">
                 <chart:AreaSeries.DataLabelSettings>
                     <chart:CartesianDataLabelSettings />
                 </chart:AreaSeries.DataLabelSettings>
             </chart:AreaSeries>
    
        </chart:SfCartesianChart>
        SfCartesianChart chart = new SfCartesianChart();
        ViewModel viewModel = new ViewModel();
    
        // Eliminated for simplicity
    
        AreaSeries series = new AreaSeries();
        series.ItemsSource = viewModel.Data;
        series.XBindingPath = "XValue";
        series.YBindingPath = "YValue";
        series.DataLabelSettings = new CartesianDataLabelSettings();
        chart.Series.Add(series);

    ShowTrackballInfo

    Gets or sets a value indicating whether to show or hide the series information when the trackball is shown.

    Declaration
    public bool ShowTrackballInfo { get; set; }
    Property Value
    Type Description
    System.Boolean

    It takes bool values and its default value is true.

    XAxisName

    Gets or sets the name of the (horizontal) axis in the XAxes collection which is used to plot the series with particular axis.

    Declaration
    public string XAxisName { get; set; }
    Property Value
    Type Description
    System.String
    Examples
    • Xaml
    • C#
        <chart:SfCartesianChart>
    
        <chart:SfCartesianChart.XAxes>
           <chart:CategoryAxis x:Name="XAxis1"/>
           <chart:NumericalAxis x:Name="XAxis2"/>
       </chart:SfCartesianChart.XAxes>
    
       <chart:SfCartesianChart.YAxes>
          <chart:NumericalAxis />
      </chart:SfCartesianChart.YAxes>
    
             <chart:SplineSeries ItemsSource="{Binding Data}"
                                 XBindingPath="XValue"
                                 YBindingPath="YValue" />
             <chart:ColumnSeries ItemsSource = "{Binding Data}"
                                 XBindingPath="XValue"
                                 YBindingPath="YValue"
                                 XAxisName="XAxis2" />
    
        </chart:SfCartesianChart>
        SfCartesianChart chart = new SfCartesianChart();
        ViewModel viewModel = new ViewModel();
    
        var XAxis1 = new CategoryAxis() { Name = "XAXis1" };
        var XAxis2 = new NumericalAxis() { Name = "XAXis2" }; 
        chart.XAxes.Add(XAxis1);
        chart.XAxes.Add(XAxis2);
        var YAxis = new NumericalAxis();
        chart.YAxes.Add(YAxis);
    
        SplineSeries splineSeries = new SplineSeries()
        {
              ItemsSource = viewModel.Data,
              XBindingPath = "XValue",
              YBindingPath = "YValue",
        };
    
        ColumnSeries columnSeries = new ColumnSeries()
        {
              ItemsSource = viewModel.Data,
              XBindingPath = "XValue",
              YBindingPath = "YValue",
              XAxisName = "XAXis2",
        };
    
        chart.Series.Add(splineSeries);
        chart.Series.Add(columnSeries);

    YAxisName

    Gets or sets the name of the (vertical) axis in the YAxes collection which is used to plot the series with particular axis.

    Declaration
    public string YAxisName { get; set; }
    Property Value
    Type Description
    System.String

    It takes the string value and its default value is null.

    Examples
    • Xaml
    • C#
        <chart:SfCartesianChart>
    
        <chart:SfCartesianChart.XAxes>
           <chart:CategoryAxis />
       </chart:SfCartesianChart.XAxes>
    
       <chart:SfCartesianChart.YAxes>
          <chart:NumericalAxis x:Name="YAxis1"/>
          <chart:NumericalAxis x:Name="YAxis2"/>
      </chart:SfCartesianChart.YAxes>
    
             <chart:SplineSeries ItemsSource="{Binding Data}"
                                 XBindingPath="XValue"
                                 YBindingPath="YValue" />
             <chart:ColumnSeries ItemsSource = "{Binding Data}"
                                 XBindingPath="XValue"
                                 YBindingPath="YValue"
                                 YAxisName="YAxis2" />
    
        </chart:SfCartesianChart>
        SfCartesianChart chart = new SfCartesianChart();
        ViewModel viewModel = new ViewModel();
    
        var XAxis = new CategoryAxis();
        chart.XAxes.Add(XAxis);
        var YAxis1 = new NumericalAxis(){Name = "YAXis1"};
        var YAxis2 = new NumericalAxis(){Name = "YAXis2"};
        chart.YAxes.Add(YAxis1);
        chart.YAxes.Add(YAxis2);
    
        SplineSeries splineSeries = new SplineSeries()
        {
              ItemsSource = viewModel.Data,
              XBindingPath = "XValue",
              YBindingPath = "YValue",
        };
    
        ColumnSeries columnSeries = new ColumnSeries()
        {
              ItemsSource = viewModel.Data,
              XBindingPath = "XValue",
              YBindingPath = "YValue",
              YAxisName = "YAXis2",
        };
    
        chart.Series.Add(splineSeries);
        chart.Series.Add(columnSeries);

    Methods

    OnApplyTemplate()

    Declaration
    protected override void OnApplyTemplate()
    Overrides
    DataMarkerSeries.OnApplyTemplate()

    Explicit Interface Implementations

    ISupportAxes.ActualXAxis

    Declaration
    ChartAxis ISupportAxes.ActualXAxis { get; }
    Returns
    Type Description
    ChartAxis

    ISupportAxes.ActualYAxis

    Declaration
    ChartAxis ISupportAxes.ActualYAxis { get; }
    Returns
    Type Description
    ChartAxis

    ISupportAxes.VisibleXRange

    Declaration
    DoubleRange ISupportAxes.VisibleXRange { get; }
    Returns
    Type Description
    DoubleRange

    ISupportAxes.VisibleYRange

    Declaration
    DoubleRange ISupportAxes.VisibleYRange { get; }
    Returns
    Type Description
    DoubleRange

    Implements

    ISupportAxes
    Back to top Generated by DocFX
    Copyright © 2001 - 2023 Syncfusion Inc. All Rights Reserved