Skip to main content

PivotDrillDownDataSource Class

Represents a list of the records which are used to calculate summaries for individual cells.

Namespace: DevExpress.XtraPivotGrid

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

NuGet Packages: DevExpress.PivotGrid.Core, DevExpress.Win.Navigation

Declaration

public abstract class PivotDrillDownDataSource :
    PivotDataSource

The following members return PivotDrillDownDataSource objects:

Show 46 links
Library Related API Members
Cross-Platform Class Library CustomExportCellEventArgsBase.CreateDrillDownDataSource()
CustomExportCellEventArgsBase.CreateDrillDownDataSource(Int32, List<String>)
CustomExportCellEventArgsBase.CreateDrillDownDataSource(Int32)
CustomExportCellEventArgsBase.CreateDrillDownDataSource(List<String>)
FieldValueCellBase.CreateDrillDownDataSource()
FieldValueCellBase.CreateDrillDownDataSource(Int32, List<String>)
FieldValueCellBase.CreateDrillDownDataSource(Int32)
FieldValueCellBase.CreateDrillDownDataSource(List<String>)
PivotCellEventArgsBase<TField, TData, TCustomTotal>.CreateDrillDownDataSource()
PivotCellEventArgsBase<TField, TData, TCustomTotal>.CreateDrillDownDataSource(Int32, List<String>)
PivotCellEventArgsBase<TField, TData, TCustomTotal>.CreateDrillDownDataSource(Int32)
PivotCellEventArgsBase<TField, TData, TCustomTotal>.CreateDrillDownDataSource(List<String>)
PivotDrillDownDataRow.DataSource
PivotFieldValueEventArgsBase<T>.CreateDrillDownDataSource()
PivotFieldValueEventArgsBase<T>.CreateDrillDownDataSource(Int32, List<String>)
PivotFieldValueEventArgsBase<T>.CreateDrillDownDataSource(Int32)
PivotFieldValueEventArgsBase<T>.CreateDrillDownDataSource(List<String>)
PivotGridCustomSummaryEventArgsBase<T>.CreateDrillDownDataSource()
WinForms Controls PivotCustomDrawCellBaseEventArgs.CreateDrillDownDataSource()
PivotCustomDrawCellBaseEventArgs.CreateDrillDownDataSource(Int32, List<String>)
PivotCustomDrawCellBaseEventArgs.CreateDrillDownDataSource(Int32)
PivotCustomDrawCellBaseEventArgs.CreateDrillDownDataSource(List<String>)
PivotFieldImageIndexEventArgs.CreateDrillDownDataSource()
PivotFieldImageIndexEventArgs.CreateDrillDownDataSource(Int32, List<String>)
PivotFieldImageIndexEventArgs.CreateDrillDownDataSource(Int32)
PivotFieldImageIndexEventArgs.CreateDrillDownDataSource(List<String>)
PivotGridControl.CreateDrillDownDataSource()
PivotGridControl.CreateDrillDownDataSource(Int32, Int32, Int32, List<String>)
PivotGridControl.CreateDrillDownDataSource(Int32, Int32, Int32)
PivotGridControl.CreateDrillDownDataSource(Int32, Int32, List<String>)
PivotGridControl.CreateDrillDownDataSource(Int32, Int32)
ASP.NET Web Forms Controls ASPxPivotGrid.CreateDrillDownDataSource()
ASPxPivotGrid.CreateDrillDownDataSource(Int32, Int32, Int32, List<String>)
ASPxPivotGrid.CreateDrillDownDataSource(Int32, Int32, Int32)
ASPxPivotGrid.CreateDrillDownDataSource(Int32, Int32, List<String>)
ASPxPivotGrid.CreateDrillDownDataSource(Int32, Int32)
PivotFieldStateChangedEventArgs.CreateDrillDownDataSource()
PivotFieldStateChangedEventArgs.CreateDrillDownDataSource(Int32, List<String>)
PivotGridCellTemplateItem.CreateDrillDownDataSource()
ASP.NET MVC Extensions PivotGridExtension.CreateDrillDownDataSource(PivotGridSettings, Object, Int32, Int32, Int32, List<String>)
PivotGridExtension.CreateDrillDownDataSource(PivotGridSettings, Object, Int32, Int32, Int32)
PivotGridExtension.CreateDrillDownDataSource(PivotGridSettings, Object, Int32, Int32, List<String>)
PivotGridExtension.CreateDrillDownDataSource(PivotGridSettings, Object, Int32, Int32)
PivotGridExtension.CreateDrillDownDataSource(PivotGridSettings, Object)
PivotGridExtension.CreateOLAPDrillDownDataSource(PivotGridSettings, String, Int32, Int32, Int32, List<String>)
PivotGridExtension.CreateOLAPDrillDownDataSource(PivotGridSettings, String, Int32, Int32, List<String>)

Remarks

The PivotDrillDownDataSource object is returned by the CreateDrillDownDataSource method, provided by the PivotGrid control. The method overloads allow you to obtain a list of the records which are used to calculate summaries for individual cells.

The PivotDrillDownDataSource class implements the IList interface, so the data returned by the CreateDrillDownDataSource method can easily be displayed in a grid control (XtraGrid or DataGrid).

Use the PivotGridControl.CreateDrillDownDataSource method to access the underlying data for a cell. In addition, the CreateDrillDownDataSource method is accessible:

Individual rows in the PivotDrillDownDataSource are represented by PivotDrillDownDataRow objects.

Use the CreateDrillDownDataSource method to retrieve the underlying data in OLAP mode.

Example

The following example shows how to display the records from the control’s underlying data source which correspond to a particular cell. A new form that displays these records is opened when a particular cell in the PivotGrid control is double-clicked.

In the example the PivotGridControl.CellDoubleClick event is handled. The PivotCellEventArgsBase<TField, TData, TCustomTotal>.CreateDrillDownDataSource method is called to obtain the list of records associated with the clicked cell.

The following image shows a sample PivotGrid control which is bound to the Invoices table in the nwind.mdb database:

CreateDrillDownDataSource_Ex_Grid

Clicking the third cell in the 1994 column will invoke the following form:

CreateDrillDownDataSource_Ex_Data

It lists all the orders made in 1994 by Belgian customers.

using DevExpress.XtraPivotGrid;

private void pivotGridControl1_CellDoubleClick(object sender, PivotCellEventArgs e) {
   // Create a new form.
   Form form = new Form();
   form.Text = "Records";
   // Place a DataGrid control on the form.
   DataGrid grid = new DataGrid();
   grid.Parent = form;
   grid.Dock = DockStyle.Fill;
   // Get the recrd set associated with the current cell and bind it to the grid.
   grid.DataSource = e.CreateDrillDownDataSource();
   form.Bounds = new Rectangle(100, 100, 500, 400);
   // Display the form.
   form.ShowDialog();
   form.Dispose();
}

Inheritance

Object
PivotDataSource
PivotDrillDownDataSource
See Also