Protected Sub loGridView_RowUpdating(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewUpdateEventArgs) Handles loGridView.RowUpdating ' Get the item to be updated Me.loGridView.EditIndex = e.RowIndex ' Retrieve the previous Order Detail DataSet Dim dsClmDetail As DataSet = CType(Session("dsClmDetail"), DataSet) ' Save the DataSet (the GridView automatically binds back) Me.Save(Me.oBxclaimd, dsClmDetail) ' Reset the edited item and rebind the GridView Me.loGridView.EditIndex = -1 Me.BindControl(Me.loGridView) End Sub