I was testing setting my grid SummaryEvaluationMode = UseLINQ to see if it would give me better performance, but i noticed that the summaries would include data that was filtered out using the grids built in filters. If i switch back to Auto than everything works as expected. Is there something I need to do to use LINQ for my summaries but still allow filtering on my grid or are those two settings not compatible for some reason. Thanks
Hello John Millage,
When SummaryEvaluationMode property is set to "UseLINQ", the summary calculations are performed based on the data source collection and if a filtering is applied, the summary value is not updated because the collection items count in the data source is not changed, the items are only filtered out in the grid and not in the collection.
What you could do is to set the XamDataGrid's DataSource to an object of ICollectionView and set FilterEvaluationMode property to "UseCollectionView". The usage of the collection view in this scenario is that it can be filtered out and the summary value will be updated properly.
Please take a look at the attached sample and let me know if you have any other questions on this matter.
Understood and thanks for the info. I would think you guys should put this somewhere in the documentation that the UseLinq summaryEvaluationMode will not work with filtering out of the box. I could not find this referenced anywhere and it could cause confusion for others.
Thank you for the feedback. I let our product guidance team know about this concern.
Please let me know if you have any other questions on this matter.