|
-
Aug 24th, 2009, 09:56 AM
#8
Thread Starter
Member
Re: sqlUpdate does not seem to work
jmcilhinney,
Thank you very very much. That was the problem. It works fine now after the changing the order of the code you mentioned.
The fix I mentioned in post # 6 also worked. I made no other changes in the code except for what I mentioned.
Thank you again.
 Originally Posted by jmcilhinney
I don't know exactly what code you're using now but this is from post #1 and it's obviously a problem:
Code:
Dim cb As New SqlCommandBuilder(sAdapter)
sAdapter = New SqlClient.SqlDataAdapter(sSQL, conn)
You can't create a command builder on a data adapter before you've created the data adapter. I can't see how the code change in post #6 would make any difference if you've done everything else properly. I've never had a problem with code like your first snippet in post #6, although I haven't used a command builder for a long time.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|