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

GGC Find row index

Thread ID:





91175 Nov 9,2009 01:31 AM UTC Nov 10,2009 08:29 AM UTC WinForms 3
Tags: Grouping
Asked On November 9, 2009 01:31 AM UTC

I am using syncfusion V6.2 grid grouping control. I need to get the total number of records in the grid. the grid for this i am using the following code:
I have grouped my grid with one column. The above piece of code works fine when all rows of the grid cell are expanded but when i collapse all rows of the grid or some rows then the row count is not correct. Actually what is happening is it doesn't count the records for collapsed row. Please let me know how to achive this. I want the complete record count irrespective of collapsed or expanded rows.

Rajadurai C [Syncfusion]
Replied On November 9, 2009 08:31 AM UTC

Hi Prabhjeet,

Thanks for your interest in Syncfusion Products.

The total number of records in gridgroupingcontrol can be retrieved through the Table.Records property. This always retrieves the number of records binded in the grid irrespective of its grouping state: collapsed or expanded.



Replied On November 10, 2009 12:17 AM UTC

The above code "ggc.Table.Records.Count" shows the number of records in grid, but i want the exact number of rows used. Please see the attached image with this query. I want all rows that are displayed in the image.
As per image when we group records there are at least 2 extra rows.


Rajadurai C [Syncfusion]
Replied On November 10, 2009 08:29 AM UTC

Hi Prabhjeet,

If you would like to count the number of rows irrespective of the type it holds. i.e., record, groupcaption, column header, etc., it can be retrieved through the elements count. Here is the code for your reference.


This computes the total number of elements present in grid. This count also includes columnheader row. To get rows other than this columnheaderrow, you have to check for the respective element, and calculate count by iterating through the Elements collection in grid.



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

This page will automatically be redirected to the 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