Im using GridDataBoundGrid with DataTable as datasource. One of the field of datatable has bool datatype and doesn''t allow null. I connected this field to checkbox in grid. If I press "del" on keybord and move to another row I get exception. Where can I handle this exception without loosing form? For example I can use string data type for field and textbox as style for column and I will receive normal message from grid, without any exception and loosing form. What am I doing wrong?
I''m using such code for checkbox:
col.StyleInfo.CellType = "CheckBox";
col.StyleInfo.CellValueType = typeof(bool);
col.StyleInfo.CheckBoxOptions = new GridCheckBoxCellInfo(true.ToString(), false.ToString(), "", true);
ADAdministrator Syncfusion Team September 3, 2004 07:00 AM
We will try to fix this. Until we have a release with it corrected, you can avoid the problem by handling grid.Model.ClearingCells and cancel the clearing if your user is trying to delete the checkbox column. You could also display a message there or you could do some special action like setting the checkbox to false in teh handler (to simulate clearing them).