Objects not showing in Print Preview, but appear when actually pri

  • Thread starter Thread starter Ryan T
  • Start date Start date
R

Ryan T

Hello,
I need to have some items appear only on the last page of my report, at the
bottom of the page. I used some code to accomplish this, and in the print
preview everything looks good. The bottom of every page is blank except the
last page, which is the way I want it. However, when I actually print the
report, the objects print on every page.

I created text boxes and labels in the Page Footer section and set the
visibile to No. I then used this code (at the On Format event in the Page
Footer properties) to display on the last page:

Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount As
Integer)
If [Page] = [Pages] Then
[TotalDue].Visible = True
[Label143].Visible = True
End If
End Sub

Any ideas how I can get these objects to only print on the last page?

Thank you.

Ryan
 
Hello,
I need to have some items appear only on the last page of my report, at the
bottom of the page. I used some code to accomplish this, and in the print
preview everything looks good. The bottom of every page is blank except the
last page, which is the way I want it. However, when I actually print the
report, the objects print on every page.

I created text boxes and labels in the Page Footer section and set the
visibile to No. I then used this code (at the On Format event in the Page
Footer properties) to display on the last page:

Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount As
Integer)
If [Page] = [Pages] Then
[TotalDue].Visible = True
[Label143].Visible = True
End If
End Sub

Any ideas how I can get these objects to only print on the last page?

Thank you.

Ryan


If [Page] = [Pages] Then
[TotalDue].Visible = True
[Label143].Visible = True
Else
[TotalDue].Visible = False
[Label143].Visible = False
End If

Or to simplify the above code:

[TotalDue].Visible = [Page] = [Pages]
[Label143].Visible = [Page] = [Pages]
 
fredg said:
Hello,
I need to have some items appear only on the last page of my report, at the
bottom of the page. I used some code to accomplish this, and in the print
preview everything looks good. The bottom of every page is blank except the
last page, which is the way I want it. However, when I actually print the
report, the objects print on every page.

I created text boxes and labels in the Page Footer section and set the
visibile to No. I then used this code (at the On Format event in the Page
Footer properties) to display on the last page:

Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount As
Integer)
If [Page] = [Pages] Then
[TotalDue].Visible = True
[Label143].Visible = True
End If
End Sub

Any ideas how I can get these objects to only print on the last page?

Thank you.

Ryan


If [Page] = [Pages] Then
[TotalDue].Visible = True
[Label143].Visible = True
Else
[TotalDue].Visible = False
[Label143].Visible = False
End If

Or to simplify the above code:

[TotalDue].Visible = [Page] = [Pages]
[Label143].Visible = [Page] = [Pages]
I tried fredg's suggestion and it still prints on all pages. Test boxes and
labels aren't visible when viewing the report on your monitor but they do
show up when printed. I've searched the posts and there doesn't seem to be a
solution. Why is it so difficult to have a report footer print at the bottom
of the page?
 
Fred,
I used the Else code below and it worked perfectly.

Thank you so much for your help.

Ryan

fredg said:
Hello,
I need to have some items appear only on the last page of my report, at the
bottom of the page. I used some code to accomplish this, and in the print
preview everything looks good. The bottom of every page is blank except the
last page, which is the way I want it. However, when I actually print the
report, the objects print on every page.

I created text boxes and labels in the Page Footer section and set the
visibile to No. I then used this code (at the On Format event in the Page
Footer properties) to display on the last page:

Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount As
Integer)
If [Page] = [Pages] Then
[TotalDue].Visible = True
[Label143].Visible = True
End If
End Sub

Any ideas how I can get these objects to only print on the last page?

Thank you.

Ryan


If [Page] = [Pages] Then
[TotalDue].Visible = True
[Label143].Visible = True
Else
[TotalDue].Visible = False
[Label143].Visible = False
End If

Or to simplify the above code:

[TotalDue].Visible = [Page] = [Pages]
[Label143].Visible = [Page] = [Pages]
 
Back
Top