(first let me say i'm sorry for my level of english...)
here is the problem;
I produce a recordset from a save query (code to follow...) then I want to extract the first colum of that recordset and group it. I tried with the sql statement but at execution, the recordset cant be found.
I did look at the variable... an it is listed and the content is ok. but it is not listed under the database, its listed under my module name...
can somebody help please...
thank for youre time...
Patrick Haines
here is the code;
Dim MaBD As Database
Dim rstTemp As Recordset
Dim strCritere As String
Set MaBD = CurrentDb
Set TableDef = MaBD.QueryDefs(NomReq)
TableDef.Parameters("MoisCour"
= MoisCour
Set TableTest = TableDef.OpenRecordset()
If TableTest.EOF Then
MsgBox "aucun rapport à produire pour cette date"
Else
strCritere = "Select An from TableTest;"
Set rstTemp = OpenRecordset(strCritere)
...
here is the problem;
I produce a recordset from a save query (code to follow...) then I want to extract the first colum of that recordset and group it. I tried with the sql statement but at execution, the recordset cant be found.
I did look at the variable... an it is listed and the content is ok. but it is not listed under the database, its listed under my module name...
can somebody help please...
thank for youre time...
Patrick Haines
here is the code;
Dim MaBD As Database
Dim rstTemp As Recordset
Dim strCritere As String
Set MaBD = CurrentDb
Set TableDef = MaBD.QueryDefs(NomReq)
TableDef.Parameters("MoisCour"
Set TableTest = TableDef.OpenRecordset()
If TableTest.EOF Then
MsgBox "aucun rapport à produire pour cette date"
Else
strCritere = "Select An from TableTest;"
Set rstTemp = OpenRecordset(strCritere)
...