统计记录失败,各们大侠,请帮我看一下这个问题哈!
Dim cnnExample As New ADODB.Connection
Dim rsExample As New ADODB.Recordset
cnnExample.Provider = "Microsoft.Jet.OLEDB.4.0"
cnnExample.ConnectionString = "data source=g:\WORK\VB\db1.mdb"
cnnExample.Open
Set rsExample.ActiveConnection = cnnExample
rsExample.Open "select * from example where example.name='" & Combo1.Text & "'"
MsgBox (rsExample.RecordCount) 在运行到此句时,总是返回记录数为-1。请问这是怎么一回事,有什么方法,可以统计出筛选出来的记录的记录数?谢谢。