Read-only dataset

  • Thread starter Thread starter Vlad
  • Start date Start date
V

Vlad

Is there anyway in ado.net to prevent any changes to the dataset tables once
those tables are already populated?
I know you can set the readonly property of each column so that the changes
are prevented once the row is added to the table, but how can I prevent the
addition and deletion of rows from the datatable?

Thanks in advance!
 
Vlad,

Michael covered most of your options. You could also capture some of the
events and spring errors. That would work on the Deletion, and probably
RowChanging would work for the insert if you checked out the RowState.
 
Back
Top