Click here to Skip to main content
15,881,581 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
See more:
VB
'SQLDATAADAPTER
Dim sda As New SdaInvoice

'DATASET          
Dim InvDataSet As New InvoicesDataSet
        
  Dim builder As New SqlCommandBuilder(sda.SqlDataAdapter1)

          sda.SqlConnection1.ConnectionString = sda.SqlConnection1.ConnectionString
          sda.SqlConnection1.Open()

          sda.SqlDataAdapter1.Fill(InvDataSet.Invoice)
          builder.GetUpdateCommand()
          sda.SqlDataAdapter1.Update(InvDataSet.Invoice)
          InvDataSet.AcceptChanges()
          sda.SqlConnection1.Close()

          grdDetails.Enabled = False
          grpInvoice.Enabled = False
Posted
Updated 22-Oct-14 22:51pm
v3
Comments
CHill60 23-Oct-14 4:52am    
So what problem are you having?
Member 10746198 23-Oct-14 4:54am    
i can't find the problem. Their are no errors. It's not updating!

1 solution

"i can't find the problem. Their are no errors. It's not updating!"

Um.
What did you expect?
What updates does it need to do? There are no changes to the data between the Fill and the Update - so there are no new or altered rows, so the total rows that require changes is zero.

It's not going to update rows which don;t need anything done! :laugh:
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900