Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

acceptchanges does not work on my datagrid/dataset

Status
Not open for further replies.

paulhudson

Programmer
Jan 20, 2005
8
GB
I have a datgrid bound to a dataset. I am using dataset.acceptchanges() to update the edited parts of the datagrid - but it fails to do this.

The OnEditCommand works fine, OnUpdateCommand simply returns datagrid exactly as it was prior to edit.

The code is:

Sub DoItemUpdate(ByVal sender As Object, ByVal e As DataGridCommandEventArgs)
Dim tpDataSet As New DataSet()
tpDataSet = Session("tpDataSet")
tpDataSet.AcceptChanges()
dgr1.DataSource = tpDataSet.Tables("TeamPlayers")
dgr1.DataBind()
End Sub

Any help would be gratefully appreciated.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top