Different Report Margins on First Page? (1 Viewer)

whdyck

Registered User.
Local time
Today, 05:00
Joined
Aug 8, 2011
Messages
169
I'm using Access 2003.

Is it possible to set the top margin on the first page of an Access report different from all the other pages?

Thanks for any help you can give.

Wayne
 

JHB

Have been here a while
Local time
Today, 12:00
Joined
Jun 17, 2012
Messages
7,732
Is it possible to set the top margin on the first page of an Access report different from all the other pages?

Thanks for any help you can give.
What are you trying to achieve, maybe it can be do on an other way?
 

whdyck

Registered User.
Local time
Today, 05:00
Joined
Aug 8, 2011
Messages
169
What are you trying to achieve, maybe it can be do on an other way?
I just want the first page to have a 1/2 inch top margin and pages 2+ to have a 1 inch margin.

Wayne
 

Mihail

Registered User.
Local time
Today, 13:00
Joined
Jan 22, 2011
Messages
2,373
Enlarge the report header until fit your requirements
 

whdyck

Registered User.
Local time
Today, 05:00
Joined
Aug 8, 2011
Messages
169
Sorry, I should have been more explicit. I want the margin on page 1 to be smaller than on succeeding pages.

I know it's an unsual question. I'm printing a form letter to company letterhead. Because of the layout of the first page, the company logo never overlaps with the text of the letter, but on pages 2+ it usually will. Yes, the simpler solution is to simply make the top margin bigger for all pages, but I've been asked to check whether it's possible to increase the margin for only pages 2+ (or reduce the margin for only page 1). Maybe it's not possible.

Thanks for your help.

Wayne
 

Mihail

Registered User.
Local time
Today, 13:00
Joined
Jan 22, 2011
Messages
2,373
I'm confused.
Try to move the company logo in the PAGE header. Is this working ?
 

whdyck

Registered User.
Local time
Today, 05:00
Joined
Aug 8, 2011
Messages
169
I'm confused.
Try to move the company logo in the PAGE header. Is this working ?
The logo is on a pre-printed form (i.e., the logo is not stored in Access), so on pages 2+ it gets overprinted with letter text from Access (unless we make the margin bigger for all pages). But because the logo is on the extreme right side of the form, page 1 would then have lots of blank space to the left of the logo. We'd like to be able to use some of that space for printing the text of the letter, not to mention that it would look a bit odd to have all that blank space, just because of the logo on the right.

Wayne
 

whdyck

Registered User.
Local time
Today, 05:00
Joined
Aug 8, 2011
Messages
169
Actually, there's more to it than I've said.

This report is in the form of a mail merge, so page 1 of the report is really just page 1 of the first letter. (Each new letter is for a new Client Number grouping.) So I really need the first page of each letter adjusted with a smaller top margin than the other pages for that letter.

But I have a solution from Doug Steele:
Declare a module-level variable (i.e.: declared at the top of the module, before any routines are defined) of the appropriate data type for Client Number. Rather than test for page number, check whether the value of that variable is the same as the current value of the Client Number. If it isn't, you're on the first page for the new client, If it is, you're on a subsequent page. The code is placed in the PageHeaderSection_Format event handler.

Code:
   If Me.txtClientNo <> mstrClientNo Then
       Me.PageHeaderSection.Height = 0
       mstrClientNo = Me.txtClientNo
   Else
       Me.PageHeaderSection.Height = 1080
   End If

Wayne
 

Mihail

Registered User.
Local time
Today, 13:00
Joined
Jan 22, 2011
Messages
2,373
Good for you and good to know.
Finally was a "play" with the header size => I'm good :)))))))

Ok Happy that you solved this and

Happy New Year to all of you !!!!!!
 

Users who are viewing this thread

Top Bottom