G
Gibson
I use the following code to open an ADO recordset of a totals query. I then
try to take the total for field TotA and put it into a variable, intTot1. I
receive an error message telling me the field (SumOfTotA)is not found in the
collection. Am I referencing it incorrectly? or possibly totals queries
can't be used as a ADO recordset? I know the value does exist in the query.
Thanks.
Set rsQry = New ADODB.Recordset
rsQry.Open SQLStmnt, CurrentProject.Connection, adOpenKeyset,
adLockOptimistic
If Not rsQry.EOF Then
intTot1 = rsQry![SumOfTotA]
End If
try to take the total for field TotA and put it into a variable, intTot1. I
receive an error message telling me the field (SumOfTotA)is not found in the
collection. Am I referencing it incorrectly? or possibly totals queries
can't be used as a ADO recordset? I know the value does exist in the query.
Thanks.
Set rsQry = New ADODB.Recordset
rsQry.Open SQLStmnt, CurrentProject.Connection, adOpenKeyset,
adLockOptimistic
If Not rsQry.EOF Then
intTot1 = rsQry![SumOfTotA]
End If