hi all,
i'm having a bit of a problem with the adapter.update command. it seems that when i navigate through my records, it updates all of it even though i didnt make any changes to some. for example, i have 15 records total, then i changed some values in the 3rd and 5th record, when i do this codes
RecordsAffected returns 15 instead of only 2. Am I doing something wrong?
please help.
thanks.
i'm having a bit of a problem with the adapter.update command. it seems that when i navigate through my records, it updates all of it even though i didnt make any changes to some. for example, i have 15 records total, then i changed some values in the 3rd and 5th record, when i do this codes
VB.NET:
Public Sub Update_Record()
Dim RecordsAffected As Int32
Dim HasChanges As String = "Transaction Complete. "
Dim Updated As String = " records applied and saved."
Dim NoChanges As String = "No changes to save."
_CurrencyManager.EndCurrentEdit()
If _DataSet.HasChanges Then
RecordsAffected = _DataAdapter.Update(_DataTable)
SBarHeadMessage(HasChanges & RecordsAffected & Updated)
Else
SBarHeadMessage(NoChanges)
End If
End Sub
RecordsAffected returns 15 instead of only 2. Am I doing something wrong?
please help.
thanks.