last page, page footer problem

J

jack

Hi,
I am trying to use the following code to give me a page
footer on the last page of a report only.
Which works great if my report is more then one page but
if it is only one page the footer doesn't appear, could
someone help

Add an unbound control to the page footer
set it's control source to =[pages]
Then code the page header format event to
Me.section(4).visible = [page] = [pages]
This will hide the entire page footer until the final page.

Thanks in advance
 
F

fredg

Hi,
I am trying to use the following code to give me a page
footer on the last page of a report only.
Which works great if my report is more then one page but
if it is only one page the footer doesn't appear, could
someone help

Add an unbound control to the page footer
set it's control source to =[pages]
Then code the page header format event to
Me.section(4).visible = [page] = [pages]
This will hide the entire page footer until the final page.

Thanks in advance

You already have a control set to = [Pages].
You can place this in the Page Footer.

If [Page] = 1 Then
Else
Cancel = Not [Page] = [Pages]
End If
 
G

Guest

Sorry Fred but I don't understand

how do i place this into the page footer?

If [Page] = 1 Then
Else
Cancel = Not [Page] = [Pages]
End If

Cheers

-----Original Message-----
Hi,
I am trying to use the following code to give me a page
footer on the last page of a report only.
Which works great if my report is more then one page but
if it is only one page the footer doesn't appear, could
someone help

Add an unbound control to the page footer
set it's control source to =[pages]
Then code the page header format event to
Me.section(4).visible = [page] = [pages]
This will hide the entire page footer until the final page.

Thanks in advance

You already have a control set to = [Pages].
You can place this in the Page Footer.

If [Page] = 1 Then
Else
Cancel = Not [Page] = [Pages]
End If


--
Fred
Please only reply to this newsgroup.
I do not reply to personal email.
.
 
J

Jack

Don't worry about the last post Fred I did the following
which works fine

Private Sub PageHeader_Format(Cancel As Integer,
FormatCount As Integer)
If Page = 1 Then
Me.Section(4).Visible = True
Else
Me.Section(4).Visible = Page = Pages
End If
End Sub

Thanks for your help

-----Original Message-----
Sorry Fred but I don't understand

how do i place this into the page footer?

If [Page] = 1 Then
Else
Cancel = Not [Page] = [Pages]
End If

Cheers

-----Original Message-----
Hi,
I am trying to use the following code to give me a page
footer on the last page of a report only.
Which works great if my report is more then one page but
if it is only one page the footer doesn't appear, could
someone help

Add an unbound control to the page footer
set it's control source to =[pages]
Then code the page header format event to
Me.section(4).visible = [page] = [pages]
This will hide the entire page footer until the final page.

Thanks in advance

You already have a control set to = [Pages].
You can place this in the Page Footer.

If [Page] = 1 Then
Else
Cancel = Not [Page] = [Pages]
End If


--
Fred
Please only reply to this newsgroup.
I do not reply to personal email.
.
.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top