I keep getting the dredded "Conversion from type 'DBNull' to type 'Boolean' is not valid." error and cannot seem to get around it.
I was getting it when I clicked on Add new record and worked around that by adding default values in code behind:
But now if I'm in insert mode, so I have clicked on Add New Record then without cancelling insert click on edit I get the error again. If I cancel the insert by clicking cancel then the error does not appear. Is there a way to cancel the insert in code behind before the grid is put in edit mode to avoid this error?