给定 ADO.Net DataRow
,我如何将行的 RowState 从更改Added
为Modified
or Deleted
?
我尝试直接设置属性:
myDataSet.Tables[0].Rows[0].RowState = DataViewRowState.ModifiedOriginal;
导致来自编译器的以下错误消息:
error CS0200: Property or indexer 'DataRow.RowState' cannot be assigned to -- it is read only