Multi-page form or report for printing

karmacable

Registered User.
Local time
Today, 05:17
Joined
Sep 13, 2011
Messages
32
I am looking to create a 5 page report based on a record.

I was initially using a form to detail my reporting (just because it simply served my needs) where I was creating the first page to exact size, using a page break and then creating the second page to size. In printing this looked great.

But now I'm attempting to create a 3rd page and it appears I've reached my limit on how long the form can be (I guess no more than 23"). I tried as well to do with a report, and it appears the same limitation is inherent.

Is there some kind of trick I can apply where I have 5 separate presized forms, or reports, and simply combine them when it's time to click the command button to view them for printing?
 
A subform for each page and a page break between each subform.
 
Great suggestion, it seems to work for printing!

However, is there a way to get the 'print preview' version to show up when a command button is clicked from the main form (e.g. so it shows all the pages). This version only shows the small subform boxes, not very helpful for my users until they print.

Thanks again for pointing in this direction.
 
If you laid it out properly it should show on screen as normal. What do you get when you switch to Print Preview mode?
 
All forms appear to have a limit of being expanded to 22". Each of my subforms are 11" (just like an 8 1/2 x 11 inch printed page). If I were to expand each subform in design view to show itself fully, my main form couldn't hold more than two. The only way you can see the full contents for all five pages is in print preview mode.

At least your subform suggestion makes it possible to place probably up to 10 subforms available for printing, helps with my general issue.

If you do know of a way to place all five subforms AND be able to view their full contents in Form view, you have my attention....
 
Right, I should have actually been saying subreport and not subform. Reports are for printing and forms are for data manipulation, so if you want more flexibility you will need to replicate your forms/subforms as reports/subreports.

For each subreport control, create a report and base the subreport control on the report by setting the Source Object accordingly. That way you can manipulate your report in its own container before viewing it as a subreport.
 
Aargh, celebrated too soon! Two more questions....

1. It appears now when I click on my command button to open my report, it sends it printing and does not pop up on the screen? I'm using;

DoCmd.OpenReport "rptDetail", , , "ProjectID=" & Me.ProjectID

The last part is simply to have it tied to the current record.

2. The code I had which referred to forms/subforms and was working before, is no longer working now that I've switched it to reports. Here's the original code;

Forms!frmDetail!subDetailCamera.Form.lbl1CA.Caption = "Whatever"

The new code I wrote in place is;

Reports!rptDetail!subDetailCamera.Report.lblCA.Caption = "Whatever"

However, the debugger tells me 'Cannot find rptDetail', even though it's there (all my forms were converted into equal named reports)....is something wrong with my syntax above?
 
Nevermind, I just figured it out in both cases. For those wishing to learn;

DoCmd.OpenReport "rptDetail", , , "ProjectID=" & Me.ProjectID
should be changed to
DoCmd.OpenReport "rptDetail", acViewReport , , "ProjectID=" & Me.ProjectID

And -

Reports!rptDetail!subDetailCamera.Report.lblCA.Caption = "Whatever"
needs an exclamation point in place of one of the periods;
Reports!rptDetail!subDetailCamera.Report!lblCA.Caption = "Whatever"
 
1. It appears now when I click on my command button to open my report, it sends it printing and does not pop up on the screen? I'm using;

DoCmd.OpenReport "rptDetail", acPreview , , "ProjectID=" & Me.ProjectID
As above in red.

2. The code I had which referred to forms/subforms and was working before, is no longer working now that I've switched it to reports. Here's the original code;

Forms!frmDetail!subDetailCamera.Form.lbl1CA.Caption = "Whatever"

The new code I wrote in place is;

Reports!rptDetail!subDetailCamera.Report.lblCA.Caption = "Whatever"

However, the debugger tells me 'Cannot find rptDetail', even though it's there (all my forms were converted into equal named reports)....is something wrong with my syntax above?
It depends where you put the code and in what event you're using this code? And why?
 

Users who are viewing this thread

Back
Top Bottom