Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Actual report (white page) doesn't fill the screen 1

Status
Not open for further replies.

SNicholls

Technical User
May 13, 2004
22
US
My report itself looks fine. However, the report (white page) does not start at the top of the screen. I have to use the scroll bar to get to the report. I'm wishing for something like a "full" view option.
Using the one page button, Fit shows the text too small, so I've tried 100% and 150%, but in every case I have to scroll to get to where the page begins; even if I try other views (e.g., two per page) and other sizes, there's still dead background space on the screen that I must scroll through before I get to the actual report. I've tried autoresize at yes and no, autocenter at yes and no. How can I fill the screen with the report?

Thank you.
SNicholls
 
Are you opening your report through a command button? If so, after your OpenReport statement, add the following code:
Code:
DoCmd.RunCommand acCmdFitToWindow
DoCmd.Maximize

Hoc nomen meum verum non est.
 
Yes, I'm using a command button. I put your code in the command button on click event. (Is that the right place?) But what happens is that then the report opens in one page-fit view. When I change fit to 100%, the dead space around the report is there again.

Here's my code:
Private Sub cmdCityReport_Click()
On Error GoTo Err_cmdCityReport_Click
Dim stDocName As String
stDocName = "rptCity"
DoCmd.OpenReport stDocName, acPreview
DoCmd.RunCommand acCmdFitToWindow
DoCmd.Maximize
Exit_cmdCityReport_Click:
Exit Sub
Err_cmdCityReport_Click:
MsgBox Err.Description
Resume Exit_cmdCityReport_Click
End Sub

I really appreciate you help.

SNicholls
 
Is the white space there on purpose??

Could you create another version of the report for viewing only that will have the controls moved up towards the top of the report??

Hoc nomen meum verum non est.
 
Is the white space there on purpose??
Not sure exactly what you mean; let me explain another way. When the screen is maximized and I use the "fit" view, the report fills the screen top to bottom but to the left and right of the report is background/blank. When I click 100% instead of fit, the report is then along the left of the screen but much larger; to the right there is background/blank, as you would expect. But there's also a lot of background/blank above the report so that I have to scroll down to get to the top of the report. I estimate that the background/blank area above the report is several inches. Since that background/blank is the standard grayish color, the white is where the report is. (The report itself looks fine.)

Could you create another version of the report for viewing only that will have the controls moved up towards the top of the report??
Not sure what you mean, but it's a tiny report with a header and six small fields - and is less than one page for three entries. I'm happy with the report, I just don't like needing to scroll down to get to the report.

I hope my explanation is clearer now.

SNicholls
 
I wonder whether it's something about how Access places objects on the screen rather than something related to a report. I noticed that any object I open is some distance down from the top of the page. Can this be set somewhere in Access?

SNicholls
 
What I meant about the white space being there on purpose was: Are the controls towards the top of the report, or further down? When I open a report at 100% zoom, I only see the top 1/2 to 2/3 of the page. Anything lower, I have to scroll.

One thing you might want to try: If you open the report with the acCmdFitToWindow command, you can then click in the middle of where your controls are in the report and it will resize to 100% with the report centered vertically where you clicked.....

Hoc nomen meum verum non est.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top