I am trying to convert the code that was written in VB using DAO to ADO.
But when i tried to do following getting an error '3251'.
*************co de************* *************
Dim cn As New ADODB.Connectio n
cn.Open "Driver={Micros oft Access Driver (*.mdb)};Dbq=c: \Website Projects\ExitCa shFlow\logMaste r\Logs.mdb;"
dim recdcath as adodb.recordset
tstrSQL = "select * from ct_enccath where cteh_reg_no ='" & txtpat(0).Text & "'"
Set recdcath = cn.Execute(tstr SQL)
recdcath.Addnew
*************** *************** *************
Please let me know what I need to add to open this up in read/write. (It stops on the recdcath.Addnew and displays the error Runtime error '3251' Current Recordset does not support updating. This may be a limitation of the Provider, or of the select Locktype).
But when i tried to do following getting an error '3251'.
*************co de************* *************
Dim cn As New ADODB.Connectio n
cn.Open "Driver={Micros oft Access Driver (*.mdb)};Dbq=c: \Website Projects\ExitCa shFlow\logMaste r\Logs.mdb;"
dim recdcath as adodb.recordset
tstrSQL = "select * from ct_enccath where cteh_reg_no ='" & txtpat(0).Text & "'"
Set recdcath = cn.Execute(tstr SQL)
recdcath.Addnew
*************** *************** *************
Please let me know what I need to add to open this up in read/write. (It stops on the recdcath.Addnew and displays the error Runtime error '3251' Current Recordset does not support updating. This may be a limitation of the Provider, or of the select Locktype).
Comment