Skip to main content
You are viewing help content for pre-release software. This document and the features it describes are subject to change. .

DxChartDonutSeries<T, TArgument, TValue> Class

OBSOLETE

Use the DxPieChartSeries in the DxPieChart component to create pie and donut charts instead.

Defines a donut series.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.1.dll

Declaration

[Obsolete("Use the DxPieChartSeries in the DxPieChart component to create pie and donut charts instead.")]
public class DxChartDonutSeries<T, TArgument, TValue> :
    DxChartXYSeries<T, TArgument, TValue, TValue>

Type Parameters

Name Description
T

The type of data.

TArgument

The type of arguments.

TValue

The type of values.

Remarks

Since v2021.2, the DxChartDonutSeries has been obsoleted (refer to this Breaking Change for more details). To create a donut chart, use the DxPieChartSeries in the DxPieChart component and specify its InnerDiameter property instead.

The following image shows a donut chart sample:

Charts - Donut series

Use the chart’s Data property to specify an IEnumerable<T> data source, and the ArgumentField and ValueField properties to specify data source fields that contain arguments and values for chart points. For a sample data source, refer to our GitHub repository.

<DxChart Data="@SalesData">
    <DxChartTitle Text="Total Sales" />
    <DxChartLegend AllowToggleSeries="true" VerticalAlignment="VerticalEdge.Bottom" Position="RelativePosition.Outside" />
    <DxChartDonutSeries ValueField="@((SaleInfo i) => i.Amount)"
                        ArgumentField="@(i => i.City)"
                        SummaryMethod="Enumerable.Sum">
        <DxChartSeriesLabel Visible="true" />
    </DxChartDonutSeries>
</DxChart>

@code {
    IEnumerable<SaleInfo> SalesData;

    protected override async Task OnInitializedAsync() {
        SalesData = (await Sales.GetSalesAsync()).Where(x => x.Country == "United States");
    }
}

Inheritance

Object
ComponentBase
DxSettingsComponent<DevExpress.Blazor.Internal.IXYChartSeriesModel>
DxComplexSettingsComponent<DxChartSeries, DevExpress.Blazor.Internal.IXYChartSeriesModel>
DxChartSeries
DxChartXYSeries<T, TArgument, TValue, TValue>
DxChartDonutSeries<T, TArgument, TValue>
See Also