Posted 26 April 2019, 2:39 am ESTHello,
I have a dataset that has over 50,000 records retrieved through a REST API call. The records become rows in a DataGrid. Many of the column values require converters on them. In order to make things more efficient and not having to load all 50,000 rows, I load the DataGrid with 100 rows. The user clicks a 'next' button and I retrieve the next hundred rows, etc... This works fine.
When I want to Group the data, only the 100 rows currently assigned to the DataGrid.Itemsource property are grouped. I would like to have the Grouping retrieve the full 50,000 records and assign them to the DataGrid.Itemsource property and then Group on them. I tried using the MyDataGrid_GroupChanging event but this is fired after the grouping of the current 100 rows is executed.
Do you have any code examples that answer the following questions:
1.) What event do I put my data access code that will retrieve the 50,000 records and then assign it to MyDataGrid.ItemSource property so that the 50,000 rows are grouped and not the currently displayed 100 rows? What event is fired when you drag a column header into the grouping area?
2.) Since these Grouped sections have thousands of rows to each group, I don't want to load them all. Instead, when the user clicks the header to expand to see the rows that make up the group, I'd like to load another subgrid (DataGrid? FlexGrid?) where only 50 rows are displayed and paging to the next/previous pages can occur.
Thanks very much,