Skip to main content
All docs
V24.2

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

DxPolarChartStackedBarSeries<T, TArgument, TValue>.Stack Property

Specifies the stack in a side-by-side stacked series.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.2.dll

NuGet Package: DevExpress.Blazor

#Declaration

C#
[DefaultValue("default")]
[Parameter]
public string Stack { get; set; }

#Property Value

Type Default Description
String "default"

The stack identifier.

#Remarks

This property is applicable only to DxPolarChartStackedBarSeries.

If you do not specify the Stack property, the Polar Chart displays one stack for each argument. The following image shows a stack for one argument value:

Ragular stacked bars

You can specify the Stack property to display side-by-side stacked charts. For example, the following image shows the Polar Chart with the same argument as the image above, except the series are divided into two stacks.

Side-by-Side Stacked Bar

Side-by-side display enhances chart readability and allows users to compare stacks displayed next to each other. The number of stacks is unlimited.

The following code snippet creates a side-by-side chart as in the image above.

<DxPolarChart T="StackedBarPoint" Data=@Data>
    <DxChartLegend Visible="false" />
    <DxChartAnimationSettings Enabled="false" />
    <DxPolarChartValueAxis></DxPolarChartValueAxis>
    <DxPolarChartStackedBarSeries Stack="male"
                                  ArgumentField="@((StackedBarPoint i) => i.State)"
                                  ValueField="@((StackedBarPoint i) => i.MaleMiddle)">
    </DxPolarChartStackedBarSeries>
    <DxPolarChartStackedBarSeries Stack="male"
                                  ArgumentField="@((StackedBarPoint i) => i.State)"
                                  ValueField="@((StackedBarPoint i) => i.MaleOlder)">
    </DxPolarChartStackedBarSeries>
    <DxPolarChartStackedBarSeries Stack="female"
                                  ArgumentField="@((StackedBarPoint i) => i.State)"
                                  ValueField="@((StackedBarPoint i) => i.FemaleMiddle)">
    </DxPolarChartStackedBarSeries>
    <DxPolarChartStackedBarSeries Stack="female"
                                  ArgumentField="@((StackedBarPoint i) => i.State)"
                                  ValueField="@((StackedBarPoint i) => i.FemaleOlder)">
    </DxPolarChartStackedBarSeries>

</DxPolarChart>

@code {
    public class StackedBarPoint {
        public string State { get; set; }
        public double MaleMiddle { get; set; }
        public double MaleOlder { get; set; }
        public double FemaleMiddle { get; set; }
        public double FemaleOlder { get; set; }
    }

    public List<StackedBarPoint> Data { get; set; }

    protected override void OnInitialized()
    {
        Data = new List<StackedBarPoint>() {
            new StackedBarPoint() {
                State = "USA",
                MaleMiddle = 90.354,
                MaleOlder = 14.472,
                FemaleMiddle = 91.827,
                FemaleOlder = 20.362
            }
        };
    }
}
See Also