G
Guest
Folks,
I have a DataGrid I've populated from a SqlCeDataAdapter. The DataGrid lives
on a Form, from which it is possible to get to a second Form allowing
creation of a new record in the table from which the SqlCeDataAdapter reads
(selects). When I close the second Form, I want the new record to appear in
the DataGrid. I can make this happen by clearing and re-filling (from the
adapter) the table which is the DataSource for the DataGrid, but I was
wondering if this is the correct approach. Should I use
SqlCeDataAdapter.InsertCommand and SqlCeDataAdapter.Update, instead?
A second, unrelated, question is, is it possible to configure the DataGrid
so that only an entire row can be selected, rather than individual cells?
Thanks,
Matthew Fleming
I have a DataGrid I've populated from a SqlCeDataAdapter. The DataGrid lives
on a Form, from which it is possible to get to a second Form allowing
creation of a new record in the table from which the SqlCeDataAdapter reads
(selects). When I close the second Form, I want the new record to appear in
the DataGrid. I can make this happen by clearing and re-filling (from the
adapter) the table which is the DataSource for the DataGrid, but I was
wondering if this is the correct approach. Should I use
SqlCeDataAdapter.InsertCommand and SqlCeDataAdapter.Update, instead?
A second, unrelated, question is, is it possible to configure the DataGrid
so that only an entire row can be selected, rather than individual cells?
Thanks,
Matthew Fleming