Data Markers in WinUI Chart

14 Apr 20211 minute to read

Chart Data Markers are used to display values related to a chart segment element. Values from data point(x, y) or other custom properties from a data source can be displayed.

Each data marker can be represented by the following:

  • Label - Displays the segment label content at the (X, Y) point.
  • Marker - Displays the desired marker at the (X, Y) point.
  • ConnectorLine - Line used to connect the (X, Y) point and the label element.

The following code example illustrates how to initialize the data marker.

<syncfusion:ColumnSeries ItemsSource="{Binding Demands}" XBindingPath="Category" YBindingPath="Value">
            <syncfusion:ChartDataMarker ShowLabel="True">
ColumnSeries series = new ColumnSeries()
    ItemsSource = ViewModel().Demands,
    XBindingPath = "Category",
    YBindingPath = "Value",
ChartDataMarker datamarker = new ChartDataMarker();
datamarker.ShowLabel = true;
series.DataMarker = datamarker;

Data Markers in WinUI