J
jp2msft
A data-bound DataGridView is wonderfully simple to include with a Windows Form.
Now that all the data is there, how do I go about adding a new record? When
I tried, Visual Studio 2005 Pro gave me an InvalidOperationException, saying,
"Rows cannot be programmatically added to the DataGridView's rows collection
when the control is data-bound."
Am I just not able to add a new record ever if I use a data-bound
DataGridView, or do I need to follow some special steps to un-data-bind it,
add my data, then re-data-bind it?
Now that all the data is there, how do I go about adding a new record? When
I tried, Visual Studio 2005 Pro gave me an InvalidOperationException, saying,
"Rows cannot be programmatically added to the DataGridView's rows collection
when the control is data-bound."
Am I just not able to add a new record ever if I use a data-bound
DataGridView, or do I need to follow some special steps to un-data-bind it,
add my data, then re-data-bind it?