Unanswered: Mulitple Report Copies with Different Label Caption
I need to print 3 copies of a report but for each copy I need to change the caption of a single label in the report header. I tried the following
Private Sub Report_Activate()
Dim intTemp As Integer
For intTemp = 1 To 3
Select Case intTemp
Me.lblCopy.Caption = "Shippers Copy"
Me.lblCopy.Caption = "Receive Copy"
Me.lblCopy.Caption = "Consignee Copy"
DoCmd.PrintOut acPrintAll, , , acHigh, 1
Only problem is this is tied to the activate event and prints 3 copies whenever this report gets the focus. Any ideas? TIA
The simplest method I know (and something I have used though admittedly it was because I had several "for your eyes only" fields as well as a public version of a report) is to:
1)Change your label to a textbox and set it's source to TheHeaderField
2)Change your recrodsource to:
SELECT "Shippers Copy" AS TheHeaderField, *
SELECT "Receive Copy", *
SELECT "Consignee Copy", *
Alternatively, have your button run the report three times. Pass the string "Shippers Copy" as the opening arg first time, Receive the second time.... you get it yes?... Have the report read it's opening arguments on opening and write the text to the label.
I thought about building the report three times with the different caption, but I thought there had to be an eaiser way. The report uses a recordset to populate some fields and takes a while to run, so I have a concern about the time it takes to build the report. I will look at changing my design I guess to make things quicker. Thanks for the post though.