Hello
I am trying to get this code to work but I keep getting "Runtime error 3061, too few paramaters.Expected2. " Any ideas??? THANKS
Dim stDocName As String
Dim db As DAO.Database
Dim rs As DAO.Recordset
Set db = CurrentDb
Set rs = db.OpenRecordset("qsrcLetter", dbOpenSnapshot)
Set rs = db.OpenRecordset("qsrcCalcTbl_Orgn", dbOpenSnapshot)
Set rs = db.OpenRecordset("qsrcCalcTbl_Firm", dbOpenSnapshot)
Do Until rs.EOF
DoCmd.OpenReport stDocName, acPreview
DoCmd.SelectObject acReport, "rptL2005_02", True
DoCmd.PrintOut acPages, 1, 2
DoCmd.OpenReport stDocName, acPreview
DoCmd.SelectObject acReport, "rptt2005_05", True
DoCmd.PrintOut acPages, 1, 1
rs.MoveNext
Loop
I am trying to get this code to work but I keep getting "Runtime error 3061, too few paramaters.Expected2. " Any ideas??? THANKS
Dim stDocName As String
Dim db As DAO.Database
Dim rs As DAO.Recordset
Set db = CurrentDb
Set rs = db.OpenRecordset("qsrcLetter", dbOpenSnapshot)
Set rs = db.OpenRecordset("qsrcCalcTbl_Orgn", dbOpenSnapshot)
Set rs = db.OpenRecordset("qsrcCalcTbl_Firm", dbOpenSnapshot)
Do Until rs.EOF
DoCmd.OpenReport stDocName, acPreview
DoCmd.SelectObject acReport, "rptL2005_02", True
DoCmd.PrintOut acPages, 1, 2
DoCmd.OpenReport stDocName, acPreview
DoCmd.SelectObject acReport, "rptt2005_05", True
DoCmd.PrintOut acPages, 1, 1
rs.MoveNext
Loop