G
Guest
I have created a query (qryMO_ProductionDaily) that uses the following
statement to choose data according to date:
Between [Forms]![frmDatesAndReportTitles]![txtDatePeriodStart] And
[Forms]![frmDatesAndReportTitles]![txtDatePeriodEnd]
This works quite nicely normally, (the form containing the dates is already
loaded) however, when I try to create a Recordset as follows:
Dim dbs As DAO.Database
Dim rstDailyProduction As DAO.Recordset
Set dbs = CurrentDb()
Set rstDailyProduction = dbs.OpenRecordset("qryMO_ProductionDaily")
I get the following error:
Error #: 3061
Too few parameters. Expected 2
How do I resolve this?
Thanks in advance for any help!
statement to choose data according to date:
Between [Forms]![frmDatesAndReportTitles]![txtDatePeriodStart] And
[Forms]![frmDatesAndReportTitles]![txtDatePeriodEnd]
This works quite nicely normally, (the form containing the dates is already
loaded) however, when I try to create a Recordset as follows:
Dim dbs As DAO.Database
Dim rstDailyProduction As DAO.Recordset
Set dbs = CurrentDb()
Set rstDailyProduction = dbs.OpenRecordset("qryMO_ProductionDaily")
I get the following error:
Error #: 3061
Too few parameters. Expected 2
How do I resolve this?
Thanks in advance for any help!