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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Event handler for detecting filtering changed when using GridExcelFilter with GridGroupingControl

Thread ID:





119348 Jun 9,2015 05:55 AM UTC Apr 5,2017 11:41 AM UTC WinForms 1
Tags: GridGroupingControl
Stephen New
Asked On June 9, 2015 05:55 AM UTC


I am having an issue using the Syncfusion.GridHelperClasses.GridExcelFilter with the Syncfusion.Windows.Forms.Grid.Grouping.GridGroupingControl.

I am using the GridExcelFilter to filter records, but I do not understand which event handler I should subscribe to, in order to detect that the user has filtered the grid.

In the attached example program (GroupingGridWithExcelFilters.zip), the following is done:
  1. The grid is initially populated with 20 records
  2. The filter is used to choose to display only 3 records
  3. There is a handler for the event GridExcelFilter.RecordFiltersItemChanged. When this handler is invoked, I use a debug breakpoint and I see that the GridGroupingControl.Table.FilteredRecords property still has 20 records...the records have NOT been filtered at this point!!
  4. I allow execution to continue, and the user interface has filtered the records so that only 3 records are shown
  5. If I push the button "Press This Button After Filtering", the button Click event handler is invoked. I used a debug breakpoint to see that the GridGroupingControl.Table.FilteredRecords property now has 3 records

So, it appears that the filtering is happening correctly...but I do not have an event (to handle) that is fired at an appropriate time. Obviously, I cannot expect the users to push a button after each time they filter records. This needs to happen automatically, when the filter is applied.

From looking in the support forums, it seems that this same issue was previously reported in June 2013, here:

However, this forum thread does not contain any indication of if/how this issue was resolved.

Can anybody suggest how I should register for an event to detect that the filters have changed?

Stephen New

Attachment: GroupingGridWithExcelFilters_3d1cf325.zip

Piruthiviraj Malaimelraj [Syncfusion]
Replied On April 5, 2017 11:41 AM UTC

Hi Stephen, 
Thanks for your interest in Syncfusion products. 
Currently GridGroupingControl does not have direct events which can be triggered after applied the excel filter. In order to get the filtered records count after excel filter is applied,  CategorizedRecords event can be used. 
Code example: 
this.gridGroupingControl1.CategorizedRecords += new TableEventHandler(gridGroupingControl1_CategorizedRecords); 
void gridGroupingControl1_CategorizedRecords(object sender, TableEventArgs e) 
    int filteredRecords = e.Table.FilteredRecords.Count; 
    MessageBox.Show("FilterRecords-Count:" + filteredRecords.ToString()); 
Sample link: 


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.

Please sign in to access our forum

or the page will be automatically redirected to sign-in page in 10 seconds.

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