Documentation on GetChanges say the following: Gets a copy of the DataSet that contains all changes made to it since it was loaded or AcceptChanges was last called.
Does this mean I can update via a stored procedure and getchanges will know, or do I need to do this update using a DataAdapter. Currently, I'm not getting any rows with GetChanges, but I'm a new programmer and it may be something entirely unrelated.
I update my data like this:
Dim UpdateVouchersCommand As New SqlCommand("spManageVouchers", Connection)
UpdateVouchersCommand.CommandType = CommandType.StoredProcedure
UpdateVouchersCommand.Parameters.AddWithValue("@or gcode", "orgcode")
UpdateVouchersInVouchingListCommand.ExecuteNonQuer y()
I then want to "refresh" the data in my dataset that this stored procedure updated:
DataTable = MyDataSet.Tables("MyTable").GetChanges()
I then use that DataTable to populate a ListView.
For me, using a stored procedure is easier for this particular function. But I'd be happy to hear feedback if this is a really bad way of doing this.
-Daranee