Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

I've created a VB app that calls data from a MS Access 2000 DB. The code pulls the data correctly and places it into the various txt boxes. However when I try to write any changed data back to the DB I get an error (see below). The data will write back fine to the data set. Its just the connection between the dataset and the data adapter that doesn't seem to be working. Help?!!??!!

 

Code nugget used:

Sub btnSave_ClickEvent(blah..........., blah......)

dataAdapterName.Update(objDataSet, "login")

End Sub

 

Error:

An unhandled exception of type 'System.InvalidOperationException' occurred in

 

system.data.dll

 

Additional information: Update requires a valid UpdateCommand when passed DataRow collection

 

with modified rows.

Posted

Nevermind. Figured it out. I needed to add the insert command to existing data adapter....the one I listed here only had the read command.

 

Thanks anyway.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...