S
Stephen Boutros
I've just installed the .NET Framework 1.1 SP1 and suddenly things that used
to work are giving me problems. Specifically, I have a grid (not an MS
DataGrid but one from a third-party) which is bound to a DataView. One of
the columns is boolean and the grid displays checkboxes, as expected. When
the user clicks on a checkbox, thereby updating the underlying data, I get
an error message from the grid: Object Reference not set to an instance of
an object. No more information than that; not very useful.
Knowing that the grid was wrapping the real exception with one of its own, I
tried to update the data "manually", i.e. as if nothing was bound to the
data view. I figured out that if I force the value of the cell in the
CellEdited even fired by this grid before the update is final, I get the
same error. Here is my line of code and the full error message:
myDataSet.myTable.Rows(rownumber).Item("MyColumn") = True
And I get:
Object reference not set to an instance of an object.
at System.Data.DataTable.RecordStateChanged(Int32 record1,
DataViewRowState oldState1, DataViewRowState newState1, Int32 record2,
DataViewRowState oldState2, DataViewRowState newState2)
at System.Data.DataTable.SetNewRecord(DataRow row, Int32 proposedRecord,
DataRowAction action, Boolean isInMerge)
at System.Data.DataRow.SetNewRecord(Int32 record)
at System.Data.DataRow.EndEdit()
at System.Data.DataRow.set_Item(DataColumn column, Object value)
at System.Data.DataRow.set_Item(String columnName, Object value)
at MyForm.MyGrid_CellEdited(Object sender, ColumnActionEventArgs e) in
myform.vb:line 3016
Just to be clear: this problem did not occur before the installation of SP1.
I've searched the Microsoft KB and found the following two articles,
downloaded the hotfixes, but they did not help:
http://support.microsoft.com/?kbid=889531
and
http://support.microsoft.com/?kbid=887549
I'm starting to run out of ideas. Somebody out there with a lead? Any help
or inspiration is appreciated at this point.
Thanks,
Steph
P.S.: watch out for the email address when replying personally.
to work are giving me problems. Specifically, I have a grid (not an MS
DataGrid but one from a third-party) which is bound to a DataView. One of
the columns is boolean and the grid displays checkboxes, as expected. When
the user clicks on a checkbox, thereby updating the underlying data, I get
an error message from the grid: Object Reference not set to an instance of
an object. No more information than that; not very useful.
Knowing that the grid was wrapping the real exception with one of its own, I
tried to update the data "manually", i.e. as if nothing was bound to the
data view. I figured out that if I force the value of the cell in the
CellEdited even fired by this grid before the update is final, I get the
same error. Here is my line of code and the full error message:
myDataSet.myTable.Rows(rownumber).Item("MyColumn") = True
And I get:
Object reference not set to an instance of an object.
at System.Data.DataTable.RecordStateChanged(Int32 record1,
DataViewRowState oldState1, DataViewRowState newState1, Int32 record2,
DataViewRowState oldState2, DataViewRowState newState2)
at System.Data.DataTable.SetNewRecord(DataRow row, Int32 proposedRecord,
DataRowAction action, Boolean isInMerge)
at System.Data.DataRow.SetNewRecord(Int32 record)
at System.Data.DataRow.EndEdit()
at System.Data.DataRow.set_Item(DataColumn column, Object value)
at System.Data.DataRow.set_Item(String columnName, Object value)
at MyForm.MyGrid_CellEdited(Object sender, ColumnActionEventArgs e) in
myform.vb:line 3016
Just to be clear: this problem did not occur before the installation of SP1.
I've searched the Microsoft KB and found the following two articles,
downloaded the hotfixes, but they did not help:
http://support.microsoft.com/?kbid=889531
and
http://support.microsoft.com/?kbid=887549
I'm starting to run out of ideas. Somebody out there with a lead? Any help
or inspiration is appreciated at this point.
Thanks,
Steph
P.S.: watch out for the email address when replying personally.