Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
185
How to get all the rows in the Grid?
posted


 Hi I just started working with Infragistics Ultrawebgrid, I am new to this so have been struggling with this problem. I have worked with the .NET 2.0 datagrid and I know you can get the total no of rows by saying

datagrid.rows.count

but with the Ifragragistics ultrawebgrid, all I see when i do that is the number of rows in the current page.
How can I get the total no of rows in the whole datagrid. since I am adding a template checkbox column I need to go through each row for the whole datagrid for the selected options. but when I do datagrid.rows.count it just displays the number of rows in the current page. Also whoever made this form is binding the grid in the Page index change event, is that effecting the grid's ability to see the total rows? Any help is appreciated.

Parents
No Data
Reply
  • 1171
    posted

    The WebGrid only binds to the rows on the current page. You can find out the total number of pages by looking at the grid's DisplayLayout.Pager.PageCount property, but I don't think this is exactly what you want. You will need to query the underlying data source to find out the complete number of rows.

    The grid works this way to improve performance in situations where there are lots of pages. The more rows there are in the grid, the more resources it needs and the more time it takes to bind. 

Children
No Data