Hi Travis,
Thank you for contacting Syncfusion support.
We have analyzed the reported query “How to achieve the drillthorugh support in the pivot grid control”. You can get the specific information for the selected cell by using the GetRawItemsFor method which is available in PivotEngine. GetRawItemsFor method is used to obtain the list of raw items for value cell, total cell or grand total cell in the pivot grid. You can find out the selected row and column index values by using CellClick event handler.
Please refer the following code sample.
#Form1.cs
private Syncfusion.Windows.Forms.Grid.GridDataBoundGrid gridDataBoundGrid1;
public Form1()
{
InitializeComponent();
InitializePivotGrid();
this.pivotGridControl1.TableControl.CellClick += TableControl_CellClick;
}
//Get the raw items for selected cells(value and sumary cells)
private void TableControl_CellClick(object sender, Syncfusion.Windows.Forms.Grid.GridCellClickEventArgs e)
{
PivotGridControlBase pivotGridControlBase = sender as PivotGridControlBase;
if (pivotGridControlBase != null)
{
int row = pivotGridControlBase.CurrentCell.RowIndex - 1;
int col = pivotGridControlBase.CurrentCell.ColIndex - 1;
var rawItems = this.pivotGridControl1.PivotEngine.GetRawItemsFor(row, col);
this.gridDataBoundGrid1.DataSource = rawItems;
}
}
|
Please let us know if you need any further assistance.
Regards,
Jagadeesan