Can anybody see a problem with this code.
I can't get any records returned into the rs object with the SELECT statement, I can get the UPDATE statement to work. I installed VB6 after VS.NET , could this cause a problem for me? I get the same problem with a Sybase and MS SQL databases.
connectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Documents and Settings\testing\Desktop\db1.mdb;Persist Security Info=False"
Dim cn As New ADODB.Connection
cn.ConnectionString = connectionString
Dim rs As New ADODB.Recordset
Set rs = cn.Execute("SELECT * FROM OrderTbl")
'this returns -1 and it should be greater than 0
This is expected behavior if you permit asynchronous row retrieval (the default). You can force all of the rows to be retrieved by navigating to the last row which will set RecordCount to the correct value.