How to get selection when the grid is grouped?

I have a sfDatagrid in my application.

When the grid is grouped, OnSelectionChanged doesn't get the selection.


Example:

                  Version        InstallDate    BugId        BugText
----------------------------------------------------------------------------------------------------------
> Program Test.exe (25 items)
                 1.0.1.233     01/02/2018     214569      Crashed on startup.
                 1.0.1.233     01/02/2018     225456      Help doesn't show.
                 1.0.1.234     15/02/2018     226897      Can't minimize.    


When I click on the grouped header, I want the selection to be Test.exe.
When I click on the second item, I want the selection to be Test.exe.

Can someone help me?

Johan  

3 Replies

GT Gnanasownthari Thirugnanam Syncfusion Team February 9, 2018 12:31 PM UTC

Hi Johan, 
 
Based on your given details we suspect your requirement like below, so please revert to us with exact requirement from below mentioned cases. 
 
  1. You had tried to select the CaptionSummaryRow (Test.exe) while click that CaptionSummaryRow or second item of Group record.
  2. Otherwise you had tried to select the all records in that group while click the CaptionSummaryRow .
 
If above mentioned two cases is not your requirement kindly revert to us with more details about your requirement like video or screenshot illustration that will be more helpful to provide appropriate solution at the earliest. 
 
Regards, 
Gnanasownthari T. 



JV Johan Visser February 12, 2018 09:30 AM UTC

Hi,

Thank you for your quick response.

Option 2 is the one closest to my needs.
When I have all the records in the group I can get the grouped field and I have all items to perform my additional selections to get details.

Johan


GT Gnanasownthari Thirugnanam Syncfusion Team February 12, 2018 10:21 AM UTC

Hi Johan, 
 
We have prepared the sample to select the group record while click on the CaptionSummaryRow (Group header as mentioned in your update) by override the HandlePointerOperations in GridSelectionController class. based on your suspicion, you can download it from below mentioned location.   
 
 
Please refer the below User Guide documentation and KB article for more details. 
  
If your requirement is different from our suspicion kindly share more details about your requirement like video or screenshot illustration that will be helpful to provide appropriate solution at the earliest.  
 
Regards, 
Gnanasownthari T. 
 


Loader.
Up arrow icon