Combining Multiple Reports into one pdf file (1 Viewer)

linskill

Registered User.
Local time
Today, 07:10
Joined
Nov 1, 2012
Messages
38
Hi Chaps,
I am using a the below code to print off reports - is there anyway to combine these reports into one pdf file?

Code:
Private Sub Command22_Click()
On Error GoTo ErrProc
DoCmd.OpenReport "FinancialReport", acViewPreview, , "AppointmentT.ApptID=" & ApptID
DoCmd.OutputTo acOutputReport, "FinancialReport", acFormatPDF, "C:\Clients\Financial.pdf"
DoCmd.Close acReport, "FinancialReport", acSaveNo

DoCmd.OpenReport "HealthReport", acViewPreview, , "HealthT.ApptID=" & Me.ApptID
DoCmd.OutputTo acOutputReport, "HealthReport", acFormatPDF, "C:\Clients\HealthReport.pdf"
DoCmd.Close acReport, "HealthReport", acSaveNo

DoCmd.OpenReport "HelpReport", acViewPreview, , "helpT.ApptID=" & Me.ApptID
DoCmd.OutputTo acOutputReport, "HelpReport", acFormatPDF, "C:\Clients\HelpReport.pdf"
DoCmd.Close acReport, "HelpReport", acSaveNo

DoCmd.OpenReport "PersonalReport", acViewPreview, , "ResillienceT.ApptID=" & Me.ApptID
DoCmd.OutputTo acOutputReport, "PersonalReport", acFormatPDF, "C:\Clients\PersonalReport.pdf"
DoCmd.Close acReport, "PersonalReport", acSaveNo

DoCmd.OpenReport "SelfEsteemReport", acViewPreview, , "SelfesteemT.ApptID=" & Me.ApptID
DoCmd.OutputTo acOutputReport, "SelfEsteemReport", acFormatPDF, "C:\Clients\SelfEsteemReport.pdf"
DoCmd.Close acReport, "SelfEsteemReport", acSaveNo

DoCmd.OpenReport "SocialReport", acViewPreview, , "SocialT.ApptID=" & Me.ApptID
DoCmd.OutputTo acOutputReport, "SocialReport", acFormatPDF, "C:\Clients\SocialReport.pdf"
DoCmd.Close acReport, "SocialReport", acSaveNo

DoCmd.OpenReport "WellbeingReport", acViewPreview, , "WellbeingT.ApptID=" & Me.ApptID
DoCmd.OutputTo acOutputReport, "WellbeingReport", acFormatPDF, "C:\Clients\WellbeingReport.pdf"
DoCmd.Close acReport, "WellbeingReport", acSaveNo
ExitProc:
    Exit Sub
ErrProc:
    Select Case Err.Number
        Case 2501
            Resume Next
        Case Else
            MsgBox Err.Number & " -- " & Err.Description
    End Select
    Resume ExitProc

End Sub
 

ebs17

Well-known member
Local time
Today, 08:10
Joined
Feb 7, 2020
Messages
1,946

Or you put your reports together as sub-reports in a gas office report and create the PDF from them.
 

Gasman

Enthusiastic Amateur
Local time
Today, 07:10
Joined
Sep 21, 2011
Messages
14,299
Have a look at this thread?
 

CJ_London

Super Moderator
Staff member
Local time
Today, 07:10
Joined
Feb 19, 2013
Messages
16,612
see these links
 

Users who are viewing this thread

Top Bottom