The difference between DataSet.GetChanges and DataSet.Copy

  • Thread starter Thread starter A.M
  • Start date Start date
A

A.M

Hi,

In which circimstance DataSet.GetChanges and DataSet.Copy return two
different DataSet?

Thanks,
Alan
 
GetChanges includes only rows that are not Unchanged (DataRow.RowState)
while Copy includes all rows regardless of their state.
 
Thanks for Miha's quick response!

Hi Alan,

GetChanges method is used to get a copy of the DataSet that contains all
changes made to it since it was loaded or AcceptChanges was last called.
Copy method copies both the structure and data for this DataSet. So, in
most circumstances, DataSet.GetChanges and DataSet.Copy returns two
different DataSets.

For more information, please check the following link:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/
frlrfsystemdatadatasetclasscopytopic.asp

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/
frlrfsystemdatadatasetclassgetchangestopic.asp

HTH.

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."
 
Back
Top