This works fine for me. If I have the following code: // Connect to the database SqlConnection conn = new SqlConnection("Server=localhost;" + "Database=ADONET;" + "Integrated Security=true;"); SqlDataAdapter da = new SqlDataAdapter("SELECT * FROM CUSTOMER", conn); conn.Open();
// Fill the DataSet DataSet dataSet = new DataSet(); da.Fill(dataSet, "Customers"); // Delete some rows DataTable custTbl = dataSet.Tables["Customers"]; custTbl.Rows[0].Delete(); custTbl.Rows[1].Delete(); // Get the Deleted Rows DataSet delDataSet = dataSet.GetChanges(DataRowState.Deleted); // Try and show the deleted rows DataTable delCustTbl = dataSet.Tables["Customers"]; Console.Write("Deleted Rows: {0}", delCustTbl.Rows.Count); I get Delted Rows: 2 Thanks, Shawn Wildermuth [EMAIL PROTECTED] > -----Original Message----- > From: dotnet discussion [mailto:[EMAIL PROTECTED]] > On Behalf Of franklin gray > Sent: Wednesday, May 01, 2002 5:21 PM > To: [EMAIL PROTECTED] > Subject: [DOTNET] dataset.GetChanges on deleted rows > > > Has anybody gotten this to work right? I get an empty > dataset. The rows have been deleted, not removed. > > TempDS = Me.DS.GetChanges(DataRowState.Deleted) > > You can read messages from the DOTNET archive, unsubscribe > from DOTNET, or subscribe to other DevelopMentor lists at > http://discuss.develop.com. > You can read messages from the DOTNET archive, unsubscribe from DOTNET, or subscribe to other DevelopMentor lists at http://discuss.develop.com.