CarlRostron
Registered User.
- Local time
- Today, 16:33
- Joined
- Nov 14, 2011
- Messages
- 88
I am trying to update an Access Table from Excel VBA and it is stopping on the update line:
It fails at :
The nerror is runtime 3251, Current Recordset does not support updating. This may be a limitation of the provider, or of the selected locktype
I appreciate any help
Code:
Set cn = New ADODB.Connection
'MyConn = ThisWorkbook.Path & Application.PathSeparator & TARGET_DB
cn.ConnectionString = "Provider = Microsoft.ACE.OLEDB.12.0;" & _
"Data Source = C:\Users\user\Desktop\Anton Kreil Mentoring\Database System\Institute DB.accdb"
MsgBox cn.ConnectionString
cn.Open
Set rs = New ADODB.Recordset
rs.Open "tblSymbol", cn, adOpenKeyset, adLockOptimistic, adCmdTable
rs.AddNew
It fails at :
Code:
rs.AddNew
I appreciate any help