CellSelected not firing
I have this set up in my sfgrid:
<GridEvents RowSelected="HandleRowSelected"
RowDeselected="HandleRowDeselected"
QueryCellInfo="CustomizeCell"
OnActionComplete="HandleActionComplete"
CellSelected="CellSelectedHandler"
TValue="TrxModel">
</GridEvents>
But CellSelectdedHandler never fires.
My grid doesn't need the Edit feature, but I tried setting that to true as a test and the event still doesn't fire.
HELP!
So, it appears this is required for cell selection:
Mode=SelectionMode.Cell
But I have another problem. I need cell selection AND I need multi-row selection with a checkbox.
And apparently, setting SelectionMode to Cell overrides Multiple Selection.
Is there any way around this?
I really need the ability to select multiple rows AND the ability to click or point or right click or even hover over a cell and be able to have the code know what cell it is and respond accordingly.
Hi Keith,
Greetings from Syncfusion support,
Query:” CellSelected not firing’
We are unable to reproduce the reported issue when attempting to reproduce the issue. We have attached screenshot and samples for your reference. If the issue persists, we will further investigate and address your specific issue.
Share grid code snippet with model class.
Could you please share a simple issue-reproducible sample.
If possible, kindly share with us your attempts to reproduce the reported issue on the above-mentioned sample.
Query:”I have another problem. I need cell selection AND
I need multi-row selection with a checkbox.”
Based on your requirement, it is not possible to use 'SelctionMode.Cell'
to perform multiple row selection and cell selection. Instead, we suggest that
you use 'SelectionMode.Both' to achieve your requirement.
|
<SfGrid DataSource="@Orders"> <GridEvents CellSelecting="CellSelectingHandler" TValue="Order"></GridEvents> <GridEditSettings AllowAdding="true" AllowEditing="true" AllowDeleting="true" Mode="EditMode.Batch"></GridEditSettings> <GridSelectionSettings Mode=SelectionMode.Both Type="SelectionType.Multiple"></GridSelectionSettings> <GridColumns> <GridColumn Type="ColumnType.CheckBox" Width="100"></GridColumn> ------- </GridColumns> </SfGrid>
|
Reference:
https://blazor.syncfusion.com/documentation/datagrid/selection#selection-mode
https://blazor.syncfusion.com/documentation/datagrid/events#cellselected
Regards,
Prathap S
Attachment: DataGrid._7e272a76.zip
- 2 Replies
- 2 Participants
-
KA Keith A Price
- Aug 13, 2023 10:57 PM UTC
- Aug 14, 2023 12:43 PM UTC