Hi,
My query is as follows;
Dim dbs As Database, rst As Recordset, rst1 As Recordset, iCount As Integer, iCount1 As Integer
' Return reference to current database.
Set dbs = CurrentDb
' Open table-type Recordset object.
Set rst = dbs.OpenRecordset("Bug")
Set rst1 = dbs.OpenRecordset("select count (closed)as count1 from bug where closed = -1")
'("SELECT count Bug FROM Bug WHERE (((Bug.Closed)=True))")
iCount = rst.RecordCount
iCount1 = rst1.RecordCount
txttotal.value = iCount
intCompleted.value = iCount1
rst.Close
Set dbs = Nothing
I am only looking to rst1, the problem is that the result is 0 or 18 (the total no of records).
Any advice?
Thanks for a great forum
Wolfgang
My query is as follows;
Dim dbs As Database, rst As Recordset, rst1 As Recordset, iCount As Integer, iCount1 As Integer
' Return reference to current database.
Set dbs = CurrentDb
' Open table-type Recordset object.
Set rst = dbs.OpenRecordset("Bug")
Set rst1 = dbs.OpenRecordset("select count (closed)as count1 from bug where closed = -1")
'("SELECT count Bug FROM Bug WHERE (((Bug.Closed)=True))")
iCount = rst.RecordCount
iCount1 = rst1.RecordCount
txttotal.value = iCount
intCompleted.value = iCount1
rst.Close
Set dbs = Nothing
I am only looking to rst1, the problem is that the result is 0 or 18 (the total no of records).
Any advice?
Thanks for a great forum
Wolfgang