We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

FilterActionCompleted Event

Thread ID:

Created:

Updated:

Platform:

Replies:

120515 Sep 22,2015 11:37 AM UTC Sep 30,2015 09:59 AM UTC WinForms 3
loading
Tags: PivotGridControl
Sérgio Rodrigues Costa
Asked On September 22, 2015 11:37 AM UTC

Hi, I´m trying to use "FilterActionCompleted" Event in a Windows Forms PivotGridControl to disable "ShowGrandTotals" on the last row, but the "FilterActionCompleted" event never gets to fire. 
Is there a better way to do it?
I have started trying to disable it in Load event. It worked, but when I made changes on filtering data, the GrandTotals returned.

Despite the fact I will use it in a VB.net app, here is the code in C#.

this.pivotGridControl1.FilterActionCompleted += new Syncfusion.Windows.Forms.PivotAnalysis.PivotGridControl.FilterActionCompletedEventArgs(this.pivotGridControl1_FilterActionCompleted);

private void pivotGridControl1_FilterActionCompleted(object sender, EventArgs e)
        {
            pivotGridControl1.ShowGrandTotals = false;
        }


Thanks in advance.

Adhikesevan Kothandaraman [Syncfusion]
Replied On September 23, 2015 10:46 AM UTC

Hi Sergio,

Thanks for contacting Syncfusion Support.

The reported scenario can be achieved by using the QueryRowHeight event, set the row height for the GrandTotal row. Please refer to the following code example,

Code Example:

void TableModel_QueryRowHeight(object sender, Syncfusion.Windows.Forms.Grid.GridRowColSizeEventArgs e)

{

    if (this.pivotGridControl1.PivotEngine[e.Index - 1, this.pivotGridControl1.PivotRows.Count].CellType

             == (PivotCellType.GrandTotalCell | PivotCellType.ValueCell))

    {

        e.Size = 0;

        e.Handled = true;

    }
}

Regards,

Adhi


Sérgio Rodrigues Costa
Replied On September 29, 2015 02:52 PM UTC

Well, I didn't found the event on with I have to trigger this function.
The "pivotGridControl1.TableModel.QueryRowHeight" event it is not exposed in VB.
I´m using VB.

Adhikesevan Kothandaraman [Syncfusion]
Replied On September 30, 2015 09:59 AM UTC

Hi Sérgio,

Thanks for your update.

Please refer to the following code example to trigger the QueryRowHeight event in VB.net,

Code Example:

AddHandler Me.pivotGridControl1.TableModel.QueryRowHeight, AddressOf TableModel_QueryRowHeight

Private Sub TableModel_QueryRowHeight(ByVal sender As Object, ByVal e As Syncfusion.Windows.Forms.Grid.GridRowColSizeEventArgs)

    If Me.pivotGridControl1.PivotEngine(e.Index - 1, Me.pivotGridControl1.PivotRows.Count).CellType = (PivotCellType.GrandTotalCell Or PivotCellType.ValueCell) Then

        e.Size = 0

        e.Handled = True

    End If
End Sub

Sample:
http://www.syncfusion.com/downloads/support/forum/120515/ze/VB568379481

Regards,
Adhi


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;