Cannot Update a change to DB Table
Posted on 2004-09-15
Thanks for clicking
I have GridEx (like a DataGrid) that's ource Table is Tbl_Alarms in an Access 2000 DB.
It bound to it through a DataAdapter and DataSet. This DataAdapter is a join between two tables Tbl_Alarms and Tbl_LocalTempAlarmsListBox.
I am simply looking to update two columns which are the only columns that can be changed (columns named ForeColor and BackColor)
Whenever I change the colour of the GridEx Row, I change the value of the columns ForeColor and BackColor to the rgb number associated.
Then after this change I send the info back to the DB table so that the changes are recorded. I do this by this code
For some reason at AcceptChanges the value recorded in ForeColor and BackColor (changed when the colors are changed) reset to DBNull.
Anybody any idea why?? Spent 2-3 hrs on this now. Your help would be most appreciated.