Error shows at set rsRecip line: Run-Time error '3061' too few parameters
Expected 1
My query as follows:
SELECT DISTINCT Students.Instructor, Students.Sect, Students.BeginDate,
Students.YYYY, Students.Sem, Students.Subject, Students.Semester,
Students.email
FROM Students
WHERE (((Students.Sect)=[Forms]![frmCensus]![cboSection]));
How to modify when my query has criteria?
How are you doing it? I would think opening a forward-only recordset
and appending the value to a string variable should work fine...
dim rsRecip as dao.recordset
set rsRecip = DBEngine(0)(0).Querydefs("qryMailMe").OpenRecordset
do until rsRecip.EOF
strRecip = strRecip & ", " & rsRecip.Fields("EmailAddress")
rsRecip.MoveNext
loop
rsRecip.close
set rsRecip=nothing
strRecip = Right$(strRecip, len(strRecip)-2)
then pass strRecip variable to your e-mail...
Error shows at set rsRecip line: Run-Time error '3061' too few parameters
Expected 1
My query as follows:
SELECT DISTINCT Students.Instructor, Students.Sect, Students.BeginDate,
Students.YYYY, Students.Sem, Students.Subject, Students.Semester,
Students.email
FROM Students
WHERE (((Students.Sect)=[Forms]![frmCensus]![cboSection]));
How to modify it when my query has criteria?