Hi Tom,
Thank you for contacting Syncfusion support.
We have analyzed your query and we are able to reproduce the reported problem “GridCheckboxColumn checkbox not enabled when the SelectionMode is None” and this is the default behavior of SfDatagrid.
And you can achieve your requirement with SelectionMode as single by using the below code snippets.
<syncfusion:SfDataGrid x:Name="sfdatagrid" Grid.Column="0"
AutoGenerateColumns="False"
AllowEditing="True"
CurrentCellBorderBrush="Transparent"
RowSelectionBrush="Transparent"
AllowGrouping="True"
ShowRowHeader="True"
SelectionUnit="Cell"
SelectionMode="Single"
ItemsSource="{Binding OrderDetails}">
public class GridCellSelectionControllerExt : GridCellSelectionController
{
public GridCellSelectionControllerExt(SfDataGrid dataGrid) : base(dataGrid)
{
}
protected override void ProcessPointerPressed(MouseButtonEventArgs args, RowColumnIndex rowColumnIndex)
{
var columnIndex = this.DataGrid.ResolveToGridVisibleColumnIndex(rowColumnIndex.ColumnIndex);
var column = this.DataGrid.Columns[columnIndex];
if (column is GridCheckBoxColumn)
{
base.ProcessPointerPressed(args, rowColumnIndex);
}
}
protected override void ProcessKeyDown(KeyEventArgs args)
{
return;
}
} |
Please find the sample from the below location.
Regards,
Jagadeesan