Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using the ADODC control
Message
From
19/08/2000 12:11:51
 
 
To
19/08/2000 11:52:52
General information
Forum:
Visual Basic
Category:
Database DAO/RDO/ODBC/ADO
Miscellaneous
Thread ID:
00407044
Message ID:
00407050
Views:
24
In addition to the above:

I said that I was using following code:
Private Sub Form_Load()
    Dim rs As New ADODB.Recordset
    rs.Open "Select * from customers", "DSN=ADOTest", adOpenKeyset, adLockPessimistic
    Set Adodc1.Recordset = rs
    Adodc1.Caption = "Customers"
End Sub
However, sometimes when I save I get the following error:

Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.

I have no idea what that error means. The error happens on the following line:

Adodc1.Recordset.Update

If I add the following details to the Adodc1 control and miss out the above code, I don't get the error:

CommandType 2 - adCmdTable
ConnectionString DSN=ADOTest
CursorType 1 - adOpenKeyset
LockType 2 - adLockPessimistic
RecordSource Customers

Any idea where I'm going wrong ? The code in Private Sub Form_Load() is from a MSFT Knowledge Base article, so I'm a bit confuse as to why it doesn't work.

Best.

Matt.
Previous
Reply
Map
View

Click here to load this message in the networking platform