Hi. I need some advice as I got stuck a little.
So, I have a windows form with a DataGridView that gets populated with table data for Add/Edit/Delete operations.
Data generally is entered through another interface and checkboxes data on database side(SQL2K) are defined as bit (NOT NULL) type.
Problem is this: when I try to create new record and tab through cells, when I move to another row, it complains that checkbox column cannot be NULL.
I expect checkboxes to have value of 0 or false, if I don't check them.
If I toggle it ON using spacebar, no error is generated but record is not saved when I close and reopen form.
Only time it works if I check checkboxes with a mouse.
I tried to set checkbox values to false on CellEnter event, if if it's null or false. This doesn't give me an error, but doesn't save record either.
The way cell gets update is this: on CellEndEdit event I call UpateData() function with sqlAdpData.Update(datData);
Any ideas how to make it working? If you need additional info, please let me know.
Thanks much.