Skip to main content
All docs

PivotCellEventArgs.CreateDrillDownDataSourceAsync(List<String>) Method

Returns data records used to calculate a summary value for the current cell asynchronously. Allows you to specify the columns to return.

Namespace: DevExpress.XtraPivotGrid

Assembly: DevExpress.XtraPivotGrid.v24.1.dll

NuGet Package: DevExpress.Win.PivotGrid


public Task<PivotDrillDownDataSource> CreateDrillDownDataSourceAsync(
    List<string> customColumns


Name Type Description
customColumns List<String>

A list of columns to return.


Type Description

An asynchronous operation that returns PivotDrillDownDataSource.


Cells in the Pivot Grid display summary and total summary values. Each summary and total summary value is calculated for a specific subset of records in the control’s underlying data source. These records are identified by the values of the column and row fields displayed within the column and row headers.

The CreateDrillDownDataSourceAsync method allows you to retrieve the subset of records from the control’s underlying data source, used to calculate the summary value for the current cell.

In Server and OLAP modes, the CreateDrillDownDataSourceAsync method returns only visible fields. To get hidden field values, use the method’s overloads with the customColumns parameter that allows you to specify the columns to return.


Run Demo: OLAP Drill Down

The code snippet below shows how to create a drill-down data source for the selected Pivot Grid cell and how to display the resulting data source in the DrillDownForm dialog.

using DevExpress.XtraEditors;
using DevExpress.XtraPivotGrid;
using System;
using System.Windows.Forms;

namespace DxSampleOLAP {
    public partial class OLAPDrillDownUserControl : XtraUserControl {
      public OLAPDrillDownUserControl() {
            pivotGridControl.OptionsBehavior.UseAsyncMode = true;
            // ...
            pivotGridControl.CellDoubleClick += async (s, e) => {
                try {
                    pivotGridControl.LoadingPanelVisible = true;
                    PivotDrillDownDataSource ds = await e.CreateDrillDownDataSourceAsync();
                    pivotGridControl.LoadingPanelVisible = false;
                    using(DrillDownForm form = new DrillDownForm(ds))
                } catch(Exception ex) {
                    pivotGridControl.LoadingPanelVisible = false;
See Also