Skip to main content

PivotChartItemType Enum

Lists values that specify the type of a PivotGridControl’s item to be represented in a ChartControl.

Namespace: DevExpress.XtraPivotGrid

Assembly: DevExpress.PivotGrid.v23.1.Core.dll

NuGet Packages: DevExpress.PivotGrid.Core, DevExpress.Win.Dashboard.Design


public enum PivotChartItemType


Name Description

A row field value is processed to be represented in the chart control.


A column field value is processed to be represented in the chart control.


A data cell value is processed to be represented in the chart control.

Related API Members

The following properties accept/return PivotChartItemType values:

Library Related API Members
WinForms Controls PivotCustomChartDataSourceDataEventArgs.ItemType
ASP.NET Web Forms Controls PivotCustomChartDataSourceDataEventArgs.ItemType


Values listed by this enumeration are used to set the ItemType property of the CustomChartDataSourceData event’s parameter (the PivotCustomChartDataSourceDataEventArgs.ItemType property for the XtraPivotGrid, and the PivotCustomChartDataSourceDataEventArgs.ItemType property for the ASPxPivotGrid).


The following example demonstrates how to add custom text to data prepared by the PivotGridControl, to display it in a ChartControl.

For this, it is necessary to handle the PivotGridControl.CustomChartDataSourceData event. In this event handler, you can determine the item type via the PivotCustomChartDataSourceDataEventArgs.ItemType property and change the PivotCustomChartDataSourceDataEventArgs.Value according to your custom requirements.

private void pivotGridControl1_CustomChartDataSourceData(object sender, 
PivotCustomChartDataSourceDataEventArgs e) {
    if(e.ItemType == PivotChartItemType.RowItem) {
        if(e.FieldValueInfo.Field == fieldCategoryName) {
            e.Value = CategoryEncodeTable[e.FieldValueInfo.Value.ToString()];
        } else if(e.FieldValueInfo.Field == fieldProductName) {
            string product =  
            string category = 
            e.Value = product + '[' + category + ']';
    if(e.ItemType == PivotChartItemType.ColumnItem) {
        if(e.FieldValueInfo.ValueType == PivotGridValueType.GrandTotal) {
            e.Value = "Total Sales";
    if(e.ItemType == PivotChartItemType.CellItem) {
        e.Value = Math.Round(Convert.ToDecimal(e.CellInfo.Value), 0);
See Also