I finally got this to work thanks to one of the board members here who pointed me in the right direction. Hopefully this solutions will help others who need to automate generating reports from parameter queries and save them as acrobat.

A little background
I need to run statements for more than 100 customers every few days and had setup this report on a parameter query (qry_cust_parameter) which asks for the customer number. I needed these reports (Statement1 to be saved as .PDF files to enable me in sending them as emails if necessary. Before executing the module, I generate a table comprising of customer numbers (tbl_cust_bal_for_stmts in my case - customers with a certain minimum balance). This table is used as the source for the parameter loop.


Sub Report1()

Dim db As DAO.Database
Dim rst As DAO.Recordset
Dim qdf As DAO.QueryDef
Dim prm As DAO.Parameter
Dim objPDF As New PDFClass
Dim strFileName As String

Set db = CurrentDb()
Set rst = db.OpenRecordset("tbl_cust_bal_for_stmts")
Set qdf = db.QueryDefs("qry_cust_parameter")
Set prm = qdf.Parameters("Enter Company ID")


Do While Not rst.EOF

prm = rst.Fields("cust_id")

qdf.Execute dbFailOnError

DoCmd.RunMacro "Statement1"

DoCmd.DeleteObject acTable, "tbl_cust_id"

strFileName = "C:\My Documents\October\over_20K\" & rst!cust_id & "_Oct_Statement.pdf"

With objPDF
.ReportName = "rpt_statement"
.OutputFile = strFileName
End With
Set objPDF = Nothing


End Sub
Let me know if you guys have any comments.