Skip to main content

PivotGridControl.GetCellValue(Object[], Object[]) Method

Returns a cell value calculated for the specified column and row field values.

Namespace: DevExpress.XtraPivotGrid

Assembly: DevExpress.XtraPivotGrid.v24.2.dll

Declaration

public object GetCellValue(
    object[] columnValues,
    object[] rowValues
)

Parameters

Name Type Description
columnValues Object[]

An array of column field values that identify the column where the cell resides.

rowValues Object[]

An array of row field values that identify the column where the cell resides.

Returns

Type Description
Object

A summary value calculated for the specified column and row field values.

Remarks

Consider the pivot grid displayed in the image below.

GetCellValue

The following table illustrates how to use the GetCellValue method to obtain specific cell values.

Cell C# Visual Basic
Red pivotGridControl.GetCellValue(new object[] {1995, 3}, new object[] {"Alice Mutton"}); pivotGridControl.GetCellValue(New Object() {1995, 3}, New Object() {"Alice Mutton"})
Green pivotGridControl.GetCellValue(new object[] {1995}, new object[] {"Aniseed Syrup"}); pivotGridControl.GetCellValue(New Object() {1995}, New Object() {"Aniseed Syrup"})
Blue pivotGridControl.GetCellValue(null, new object[] {"Boston Crab Meat"}); pivotGridControl.GetCellValue(Nothing, New Object() {"Boston Crab Meat"})

Note

If there are two or more data fields, an exception is raised by this overload of the GetCellValue method. To retrieve cell values when there is more than one data field, use the GetCellValue method overload that takes a dataField parameter.

See Also