Laura
unread,Feb 9, 2009, 7:46:22 AM2/9/09Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to DotNetDevelopment, VB.NET, C# .NET, ADO.NET, ASP.NET, XML, XML Web Services,.NET Remoting
Thanks for that.
I wrote some code as follows:
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnSave.Click
Dim modifiedChildRecords As DataSet2.TodaysAbsenteesDataTable
= _
CType(DataSet2.TodaysAbsentees.GetChanges
(Data.DataRowState.Modified), _
DataSet2.TodaysAbsenteesDataTable)
Try
If modifiedChildRecords IsNot Nothing Then
TodaysAbsentessTableAdapter.Update
(modifiedChildRecords)
End If
TodaysAbsentessTableAdapter.Update
(DataSet2.TodaysAbsentees)
DataSet2.AcceptChanges()
MsgBox("Update Successful!")
Catch ex As Exception
MsgBox("Update Failed!")
Finally
If modifiedChildRecords IsNot Nothing Then
modifiedChildRecords.Dispose()
End If
End Try
End Sub
However it's not updating. Am I missing something?
From the code i have just added, I'm obviously trying to update the
tableadabter, is that right? If the tableadapter is updated, does that
mean that the related tables get updated?
Thanks,
> > Thanks!- Hide quoted text -
>
> - Show quoted text -