M
mickarlsmith
I have this code and a query called Q_ExportToOutlook, but when i try
and run it i get the message 'Item not found in Collection'. I have
copied the Parameter straight from the Query SQL and then deleted it
from the SQL for the query.
This is the code i have running off the button-
Dim dbs As Database
Dim rst As Recordset
Dim qd As QueryDef
Set dbs = CurrentDb()
Set qd = dbs.QueryDefs("Q_ExportToOutlook")
qd.Parameters![tblStaffSelect.StaffID] = [Forms]!
[frmExportToOutlook].[StaffSelect]
Can anyone tell me what i'm missing?
and run it i get the message 'Item not found in Collection'. I have
copied the Parameter straight from the Query SQL and then deleted it
from the SQL for the query.
This is the code i have running off the button-
Dim dbs As Database
Dim rst As Recordset
Dim qd As QueryDef
Set dbs = CurrentDb()
Set qd = dbs.QueryDefs("Q_ExportToOutlook")
qd.Parameters![tblStaffSelect.StaffID] = [Forms]!
[frmExportToOutlook].[StaffSelect]
Can anyone tell me what i'm missing?