How to set page header to invisible using vba

dealwi8me

Registered User.
Local time
Today, 02:21
Joined
Jan 5, 2005
Messages
187
Hello,

What i need is to set invisible the page header in the first page.
I'm using the following code, i succeed what i want in screen but when i print i get the page header in all pages.

Code:
If Me.Page > 0 Then
Me.PageHeaderSection.Visible = True
Else
Me.PageHeaderSection.Visible = False
End If

Any ideas what i do wrong?

Thank you in advance.
 
I used the following and worked

Code:
Private Sub PageHeaderSection_Format(Cancel As Integer, FormatCount As Integer)
Cancel = Me.[Page] = 1
End Sub
 
Thanks. This really saved me a great deal of time. I didn't want the page header to be printed on the second page so I changed the 1 to a 2 and it worked great.
 

Users who are viewing this thread

Back
Top Bottom