-
RecordCount -1
I understand that Cursor location can cause this problem. I tried to put cursor location and it prompts me error, it said
Arguement is wrong type or conflict with another or out of acceptable range. Kindly, assist me please. Thanks. Below is my code.
This is actually in VB script
Code:
set myConnection = CreateObject("ADODB.Connection")
set SQLrecordset = CreateObject("ADODB.Recordset")
myConnection.Open = "DSN=cnote;SOURCE=localhost;DATABASE=eai;user id='atoo';password='rtor' "
myconnection.CursorLocation = adUseClient ' Error here
VarSQL = "SELECT * FROM agcn_process where CN_CODE = '"&RstID&"' "
SQLrecordset.Open VarSQL, myConnection
-
Re: RecordCount -1
Quote:
Originally posted by kokzai
I understand that Cursor location can cause this problem. I tried to put cursor location and it prompts me error, it said
Arguement is wrong type or conflict with another or out of acceptable range. Kindly, assist me please. Thanks. Below is my code.
This is actually in VB script
Code:
set myConnection = CreateObject("ADODB.Connection")
set SQLrecordset = CreateObject("ADODB.Recordset")
myConnection.Open = "DSN=cnote;SOURCE=localhost;DATABASE=eai;user id='atoo';password='rtor' "
myconnection.CursorLocation = adUseClient ' Error here
VarSQL = "SELECT * FROM agcn_process where CN_CODE = '"&RstID&"' "
SQLrecordset.Open VarSQL, myConnection
Well try specifying the cursorlocation for the recordset instead
-
Also u need to set the cursorlocation before opening the connexion not after opening