this must be easy! I want to put some stuff at the end of the rpt

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

sometimes my report is 1 page. sometimes there is enough data to fill 2 or 3
or 4 pages. I have some stuff (a couple labels and some text) that I want to
appear always at the very bottom of the last page. But I don't want it to
appear at the bottom of any of the other pages. How can I do this? It must
be easy!
 
Use the Report Footer section for those textboxes... this section prints
only at the bottom of the last page.
 
Hello Ken,
Well, I may be crazy, but I just made a report from scratch. I put 3
records in the table underlying the report, and I added a report footer. I'm
afraid the report footer comes right after the 3rd record! It is definitely
not at the bottom of the page. And this is the easy case, there is only 1
page in my report!
 
But I do not want to print my last section of stuff after the detail
section... I want it at the Bottom of the last page!

I included that top property in my else clause. It did not help.

Ken Snell said:
Told you it wasn't easy < g >.

Trying to set the height property of the report footer section while in the
page footer section probably is going to lead to problems. I also note that
you're not setting the Top property of the Txt2 textbox in the "Else"
portion of the block.

In order for ACCESS to "generate" a report where you are using the Pages
property, it must format every page of the report in order to get a Pages
value, then it formats each page again as you print/view it. Thus, it's
possible for ACCESS to become confused, as you're seeing.

I've run across another trick that might work for you. Are you using a
grouping in the detail section? If not (or even if you are), create a new
group as the first group (Sorting and Grouping menu), and group on the
number 1. Select to have group header and footer sections. Then put your
"last page" data in that group's footer section. This section will print
only after all data have been printed in the Detail section. That also may
do what you seek.
--

Ken Snell
<MS ACCESS MVP>





oops, I take it back. It worked fine while previewing the report on the
screen. But it PRINTS ON THE PRINTER TOTALLY DIFFERENTLY!! Unbelievable.
For example, instead of 5 pages it prints 6 pages. (and on the 5th page
my
textbox even shows page 5 of 5). Here is my code:
Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount As
Integer)
If ([Page] = Pages) Then
Me.txt1.Visible = True
Me.Txt2.Visible = True
Me.PageFooterSection.Height = 3 * 1440
Me.ReportFooter.Height = 0 * 1440
Me.Txt2.Top = 1 * 1440
Else
Me.txt1.Visible = False
Me.Txt2.Visible = False
Me.PageFooterSection.Height = 0 * 1440
Me.ReportFooter.Height = 3 * 1440
End If

Ken Snell said:
Well, now, I find that the code doesn't do what I had thought.... but if
you
put an invisible textbox in the page footer section that uses an
expression
involving the [Pages] property (control source would be
=[Pages]
)

then it will work. Reports sometimes require a control to be on the
report
where the control uses a field that is being used in code or other
controls
or properties.

--

Ken Snell
<MS ACCESS MVP>




are you sure about this stuff? I can't even get this to work:
Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount As
Integer)

If ([Page] = [Pages]) Then
Me.Label11.Visible = True
End If
End Sub

that should turn on the visibility of the label that is in the page
footer
section... But it doesn't.

Earlier I had mixed success turning that label's visibility on and off
(on
page 2 for example) but it doesn't seem consistent. I think I am
missing
something here.

:

Additional note....

If the label is at the top of the page footer section, changing its
height
most likely will still leave white space, as the section's height is
not
being changed as well. You'd also need to reduce the height of the
footer
section and change the Top property of the controls that are below
that
label. (You're now seeing an example of what my first reply was
suggesting
would be involved with trying to change the location of the report
footer.)
--

Ken Snell
<MS ACCESS MVP>



Then change its height to zero when you make it invisible:

Select Case ([Page]=[Pages])
Case True
Me.ControlName.Visible = True
Me.ControlName.Height = 1440 * NumberOfInchesHigh
Case False
Me.ControlName.Visible = False
Me.ControlName.Height = 0
End Select

--

Ken Snell
<MS ACCESS MVP>


OK, I have just tried this. The problem with this approach is that
the
control still wastes space on the first pages where it is not
visible.
I
can
turn the label's visibility on and off fine (making it visible only
on
the
last page) but it is a pretty big control (2" high at least) and it
looks
terrible to have 2" of blank space at the bottom of those first
pages...

:

Actually, you might be able to use the Page Footer section for
what
you
seek.

You can put code in the Format event of the PageFooter section to
test
if
[Page]=[Pages], and use that for setting the visible property of
the
textboxes/controls that are to print only on the last page.

Me.ControlName.Visible = ([Page]=[Pages])

This might get you what you want more easily.

--

Ken Snell
<MS ACCESS MVP>


message
Sorry... I slightly misread your question. No, you're correct in
what
you
see.. the report footer prints after the last data record for
the
report.
There is no built-in way to make the report footer go to the
bottom.
You
must do it via some "tricky" programming that has to check the
"height" of
the last page, determine the "height" of your footer, subtract
the
two,
and calculate how much "white space" to be put into the footer,
which
probably would be done by changing the height of the textboxes
in
the
footer and then adding blank lines to the beginning of the text
in
those
textboxes so that the data print at the bottom.

However, Stephen Lebans may have something already worked out
for
this...
see his site www.lebans.com.

--

Ken Snell
<MS ACCESS MVP>


Hello Ken,
Well, I may be crazy, but I just made a report from scratch.
I
put
3
records in the table underlying the report, and I added a
report
footer.
I'm
afraid the report footer comes right after the 3rd record! It
is
definitely
not at the bottom of the page. And this is the easy case,
there
is
only
1
page in my report!

:

Use the Report Footer section for those textboxes... this
section
prints
only at the bottom of the last page.

--

Ken Snell
<MS ACCESS MVP>

sometimes my report is 1 page. sometimes there is enough
data
to
fill
2
or 3
or 4 pages. I have some stuff (a couple labels and some
text)
that I
want
to
appear always at the very bottom of the last page. But I
don't
want
it to
appear at the bottom of any of the other pages. How can I
do
this?
It
must
be easy!
 
As I have noted, what you seek is not straightforward nor easy -- it's not
built into ACCESS as a standard feature.

I do not have a solution already worked out. I just checked Stephen Lebans'
web site and I don't see that he has a utility to do what you seek.

It will require some complicated programming to try to do what you seek, and
you may need to hire a programmer/developer to come up with the solution for
your particular setup.

--

Ken Snell
<MS ACCESS MVP>



But I do not want to print my last section of stuff after the detail
section... I want it at the Bottom of the last page!

I included that top property in my else clause. It did not help.

Ken Snell said:
Told you it wasn't easy < g >.

Trying to set the height property of the report footer section while in
the
page footer section probably is going to lead to problems. I also note
that
you're not setting the Top property of the Txt2 textbox in the "Else"
portion of the block.

In order for ACCESS to "generate" a report where you are using the Pages
property, it must format every page of the report in order to get a Pages
value, then it formats each page again as you print/view it. Thus, it's
possible for ACCESS to become confused, as you're seeing.

I've run across another trick that might work for you. Are you using a
grouping in the detail section? If not (or even if you are), create a new
group as the first group (Sorting and Grouping menu), and group on the
number 1. Select to have group header and footer sections. Then put your
"last page" data in that group's footer section. This section will print
only after all data have been printed in the Detail section. That also
may
do what you seek.
--

Ken Snell
<MS ACCESS MVP>





oops, I take it back. It worked fine while previewing the report on
the
screen. But it PRINTS ON THE PRINTER TOTALLY DIFFERENTLY!!
Unbelievable.
For example, instead of 5 pages it prints 6 pages. (and on the 5th
page
my
textbox even shows page 5 of 5). Here is my code:
Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount As
Integer)
If ([Page] = Pages) Then
Me.txt1.Visible = True
Me.Txt2.Visible = True
Me.PageFooterSection.Height = 3 * 1440
Me.ReportFooter.Height = 0 * 1440
Me.Txt2.Top = 1 * 1440
Else
Me.txt1.Visible = False
Me.Txt2.Visible = False
Me.PageFooterSection.Height = 0 * 1440
Me.ReportFooter.Height = 3 * 1440
End If

:

Well, now, I find that the code doesn't do what I had thought.... but
if
you
put an invisible textbox in the page footer section that uses an
expression
involving the [Pages] property (control source would be
=[Pages]
)

then it will work. Reports sometimes require a control to be on the
report
where the control uses a field that is being used in code or other
controls
or properties.

--

Ken Snell
<MS ACCESS MVP>




are you sure about this stuff? I can't even get this to work:
Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount
As
Integer)

If ([Page] = [Pages]) Then
Me.Label11.Visible = True
End If
End Sub

that should turn on the visibility of the label that is in the page
footer
section... But it doesn't.

Earlier I had mixed success turning that label's visibility on and
off
(on
page 2 for example) but it doesn't seem consistent. I think I am
missing
something here.

:

Additional note....

If the label is at the top of the page footer section, changing its
height
most likely will still leave white space, as the section's height
is
not
being changed as well. You'd also need to reduce the height of the
footer
section and change the Top property of the controls that are below
that
label. (You're now seeing an example of what my first reply was
suggesting
would be involved with trying to change the location of the report
footer.)
--

Ken Snell
<MS ACCESS MVP>



message
Then change its height to zero when you make it invisible:

Select Case ([Page]=[Pages])
Case True
Me.ControlName.Visible = True
Me.ControlName.Height = 1440 * NumberOfInchesHigh
Case False
Me.ControlName.Visible = False
Me.ControlName.Height = 0
End Select

--

Ken Snell
<MS ACCESS MVP>


OK, I have just tried this. The problem with this approach is
that
the
control still wastes space on the first pages where it is not
visible.
I
can
turn the label's visibility on and off fine (making it visible
only
on
the
last page) but it is a pretty big control (2" high at least) and
it
looks
terrible to have 2" of blank space at the bottom of those first
pages...

:

Actually, you might be able to use the Page Footer section for
what
you
seek.

You can put code in the Format event of the PageFooter section
to
test
if
[Page]=[Pages], and use that for setting the visible property
of
the
textboxes/controls that are to print only on the last page.

Me.ControlName.Visible = ([Page]=[Pages])

This might get you what you want more easily.

--

Ken Snell
<MS ACCESS MVP>


message
Sorry... I slightly misread your question. No, you're correct
in
what
you
see.. the report footer prints after the last data record for
the
report.
There is no built-in way to make the report footer go to the
bottom.
You
must do it via some "tricky" programming that has to check
the
"height" of
the last page, determine the "height" of your footer,
subtract
the
two,
and calculate how much "white space" to be put into the
footer,
which
probably would be done by changing the height of the
textboxes
in
the
footer and then adding blank lines to the beginning of the
text
in
those
textboxes so that the data print at the bottom.

However, Stephen Lebans may have something already worked out
for
this...
see his site www.lebans.com.

--

Ken Snell
<MS ACCESS MVP>


Hello Ken,
Well, I may be crazy, but I just made a report from
scratch.
I
put
3
records in the table underlying the report, and I added a
report
footer.
I'm
afraid the report footer comes right after the 3rd record!
It
is
definitely
not at the bottom of the page. And this is the easy case,
there
is
only
1
page in my report!

:

Use the Report Footer section for those textboxes... this
section
prints
only at the bottom of the last page.

--

Ken Snell
<MS ACCESS MVP>

sometimes my report is 1 page. sometimes there is enough
data
to
fill
2
or 3
or 4 pages. I have some stuff (a couple labels and some
text)
that I
want
to
appear always at the very bottom of the last page. But I
don't
want
it to
appear at the bottom of any of the other pages. How can
I
do
this?
It
must
be easy!
 
Well. I know it's not a standard feature in Access.

I don't really care what is in stephan lebans' site, unless it helps me
directly with my problem.

I don't mind complicated programming, but I thought this newsgroup was here
for guidance. I AM a programmer / developer and need to get this thing done.


Is there no further escalation of this issue, or are we content with the
solution that "it's difficult"? Thanks for trying-

Ken Snell said:
As I have noted, what you seek is not straightforward nor easy -- it's not
built into ACCESS as a standard feature.

I do not have a solution already worked out. I just checked Stephen Lebans'
web site and I don't see that he has a utility to do what you seek.

It will require some complicated programming to try to do what you seek, and
you may need to hire a programmer/developer to come up with the solution for
your particular setup.

--

Ken Snell
<MS ACCESS MVP>



But I do not want to print my last section of stuff after the detail
section... I want it at the Bottom of the last page!

I included that top property in my else clause. It did not help.

Ken Snell said:
Told you it wasn't easy < g >.

Trying to set the height property of the report footer section while in
the
page footer section probably is going to lead to problems. I also note
that
you're not setting the Top property of the Txt2 textbox in the "Else"
portion of the block.

In order for ACCESS to "generate" a report where you are using the Pages
property, it must format every page of the report in order to get a Pages
value, then it formats each page again as you print/view it. Thus, it's
possible for ACCESS to become confused, as you're seeing.

I've run across another trick that might work for you. Are you using a
grouping in the detail section? If not (or even if you are), create a new
group as the first group (Sorting and Grouping menu), and group on the
number 1. Select to have group header and footer sections. Then put your
"last page" data in that group's footer section. This section will print
only after all data have been printed in the Detail section. That also
may
do what you seek.
--

Ken Snell
<MS ACCESS MVP>





oops, I take it back. It worked fine while previewing the report on
the
screen. But it PRINTS ON THE PRINTER TOTALLY DIFFERENTLY!!
Unbelievable.
For example, instead of 5 pages it prints 6 pages. (and on the 5th
page
my
textbox even shows page 5 of 5). Here is my code:
Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount As
Integer)
If ([Page] = Pages) Then
Me.txt1.Visible = True
Me.Txt2.Visible = True
Me.PageFooterSection.Height = 3 * 1440
Me.ReportFooter.Height = 0 * 1440
Me.Txt2.Top = 1 * 1440
Else
Me.txt1.Visible = False
Me.Txt2.Visible = False
Me.PageFooterSection.Height = 0 * 1440
Me.ReportFooter.Height = 3 * 1440
End If

:

Well, now, I find that the code doesn't do what I had thought.... but
if
you
put an invisible textbox in the page footer section that uses an
expression
involving the [Pages] property (control source would be
=[Pages]
)

then it will work. Reports sometimes require a control to be on the
report
where the control uses a field that is being used in code or other
controls
or properties.

--

Ken Snell
<MS ACCESS MVP>




are you sure about this stuff? I can't even get this to work:
Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount
As
Integer)

If ([Page] = [Pages]) Then
Me.Label11.Visible = True
End If
End Sub

that should turn on the visibility of the label that is in the page
footer
section... But it doesn't.

Earlier I had mixed success turning that label's visibility on and
off
(on
page 2 for example) but it doesn't seem consistent. I think I am
missing
something here.

:

Additional note....

If the label is at the top of the page footer section, changing its
height
most likely will still leave white space, as the section's height
is
not
being changed as well. You'd also need to reduce the height of the
footer
section and change the Top property of the controls that are below
that
label. (You're now seeing an example of what my first reply was
suggesting
would be involved with trying to change the location of the report
footer.)
--

Ken Snell
<MS ACCESS MVP>



message
Then change its height to zero when you make it invisible:

Select Case ([Page]=[Pages])
Case True
Me.ControlName.Visible = True
Me.ControlName.Height = 1440 * NumberOfInchesHigh
Case False
Me.ControlName.Visible = False
Me.ControlName.Height = 0
End Select

--

Ken Snell
<MS ACCESS MVP>


OK, I have just tried this. The problem with this approach is
that
the
control still wastes space on the first pages where it is not
visible.
I
can
turn the label's visibility on and off fine (making it visible
only
on
the
last page) but it is a pretty big control (2" high at least) and
it
looks
terrible to have 2" of blank space at the bottom of those first
pages...

:

Actually, you might be able to use the Page Footer section for
what
you
seek.

You can put code in the Format event of the PageFooter section
to
test
if
[Page]=[Pages], and use that for setting the visible property
of
the
textboxes/controls that are to print only on the last page.

Me.ControlName.Visible = ([Page]=[Pages])

This might get you what you want more easily.

--

Ken Snell
<MS ACCESS MVP>


message
Sorry... I slightly misread your question. No, you're correct
in
what
you
see.. the report footer prints after the last data record for
the
report.
There is no built-in way to make the report footer go to the
bottom.
You
must do it via some "tricky" programming that has to check
the
"height" of
the last page, determine the "height" of your footer,
subtract
the
two,
and calculate how much "white space" to be put into the
footer,
which
probably would be done by changing the height of the
textboxes
in
the
footer and then adding blank lines to the beginning of the
text
in
those
textboxes so that the data print at the bottom.

However, Stephen Lebans may have something already worked out
for
this...
see his site www.lebans.com.

--

Ken Snell
<MS ACCESS MVP>


Hello Ken,
Well, I may be crazy, but I just made a report from
scratch.
I
put
3
records in the table underlying the report, and I added a
report
footer.
I'm
afraid the report footer comes right after the 3rd record!
It
is
definitely
not at the bottom of the page. And this is the easy case,
there
is
only
1
page in my report!

:

Use the Report Footer section for those textboxes... this
section
prints
only at the bottom of the last page.

--

Ken Snell
<MS ACCESS MVP>

news:[email protected]...
 
Well. I know it's not a standard feature in Access.

I don't really care what is in stephan lebans' site, unless it helps me
directly with my problem.

I don't mind complicated programming, but I thought this newsgroup was here
for guidance. I AM a programmer / developer and need to get this thing done.


Is there no further escalation of this issue, or are we content with the
solution that "it's difficult"? Thanks for trying-


Perhaps...

Determine in the page event when you are on the last page of the report and then
use the print method to insert the text you want at the bottom of the page.
 
If I were "between jobs", I might take some time to try to work out a
solution... but, alas, I am "working" on a number of jobs at the moment. And
no, not working for Microsoft -- I am a volunteer here in the newsgroups.

It's an interesting challenge to write generic code that would do what you
seek... but I do not have time to do it right now for no compensation.

I mentioned Stephen Lebans' site because Stephen has many such utilities and
so I looked there... I apologize that that information seemed unnecessary
and out of context, but .. I had mentioned Stephen's site earlier in our
thread, so I figured I would close the loop.

I have given you some ideas on a concept for handling this; at the moment,
that is the best I can offer to you. I am sorry.
--

Ken Snell
<MS ACCESS MVP>



Well. I know it's not a standard feature in Access.

I don't really care what is in stephan lebans' site, unless it helps me
directly with my problem.

I don't mind complicated programming, but I thought this newsgroup was
here
for guidance. I AM a programmer / developer and need to get this thing
done.


Is there no further escalation of this issue, or are we content with the
solution that "it's difficult"? Thanks for trying-

Ken Snell said:
As I have noted, what you seek is not straightforward nor easy -- it's
not
built into ACCESS as a standard feature.

I do not have a solution already worked out. I just checked Stephen
Lebans'
web site and I don't see that he has a utility to do what you seek.

It will require some complicated programming to try to do what you seek,
and
you may need to hire a programmer/developer to come up with the solution
for
your particular setup.

--

Ken Snell
<MS ACCESS MVP>



But I do not want to print my last section of stuff after the detail
section... I want it at the Bottom of the last page!

I included that top property in my else clause. It did not help.

:

Told you it wasn't easy < g >.

Trying to set the height property of the report footer section while
in
the
page footer section probably is going to lead to problems. I also note
that
you're not setting the Top property of the Txt2 textbox in the "Else"
portion of the block.

In order for ACCESS to "generate" a report where you are using the
Pages
property, it must format every page of the report in order to get a
Pages
value, then it formats each page again as you print/view it. Thus,
it's
possible for ACCESS to become confused, as you're seeing.

I've run across another trick that might work for you. Are you using a
grouping in the detail section? If not (or even if you are), create a
new
group as the first group (Sorting and Grouping menu), and group on the
number 1. Select to have group header and footer sections. Then put
your
"last page" data in that group's footer section. This section will
print
only after all data have been printed in the Detail section. That also
may
do what you seek.
--

Ken Snell
<MS ACCESS MVP>





oops, I take it back. It worked fine while previewing the report on
the
screen. But it PRINTS ON THE PRINTER TOTALLY DIFFERENTLY!!
Unbelievable.
For example, instead of 5 pages it prints 6 pages. (and on the 5th
page
my
textbox even shows page 5 of 5). Here is my code:
Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount
As
Integer)
If ([Page] = Pages) Then
Me.txt1.Visible = True
Me.Txt2.Visible = True
Me.PageFooterSection.Height = 3 * 1440
Me.ReportFooter.Height = 0 * 1440
Me.Txt2.Top = 1 * 1440
Else
Me.txt1.Visible = False
Me.Txt2.Visible = False
Me.PageFooterSection.Height = 0 * 1440
Me.ReportFooter.Height = 3 * 1440
End If

:

Well, now, I find that the code doesn't do what I had thought....
but
if
you
put an invisible textbox in the page footer section that uses an
expression
involving the [Pages] property (control source would be
=[Pages]
)

then it will work. Reports sometimes require a control to be on the
report
where the control uses a field that is being used in code or other
controls
or properties.

--

Ken Snell
<MS ACCESS MVP>




are you sure about this stuff? I can't even get this to work:
Private Sub PageFooterSection_Format(Cancel As Integer,
FormatCount
As
Integer)

If ([Page] = [Pages]) Then
Me.Label11.Visible = True
End If
End Sub

that should turn on the visibility of the label that is in the
page
footer
section... But it doesn't.

Earlier I had mixed success turning that label's visibility on
and
off
(on
page 2 for example) but it doesn't seem consistent. I think I am
missing
something here.

:

Additional note....

If the label is at the top of the page footer section, changing
its
height
most likely will still leave white space, as the section's
height
is
not
being changed as well. You'd also need to reduce the height of
the
footer
section and change the Top property of the controls that are
below
that
label. (You're now seeing an example of what my first reply was
suggesting
would be involved with trying to change the location of the
report
footer.)
--

Ken Snell
<MS ACCESS MVP>



message
Then change its height to zero when you make it invisible:

Select Case ([Page]=[Pages])
Case True
Me.ControlName.Visible = True
Me.ControlName.Height = 1440 * NumberOfInchesHigh
Case False
Me.ControlName.Visible = False
Me.ControlName.Height = 0
End Select

--

Ken Snell
<MS ACCESS MVP>


OK, I have just tried this. The problem with this approach
is
that
the
control still wastes space on the first pages where it is not
visible.
I
can
turn the label's visibility on and off fine (making it
visible
only
on
the
last page) but it is a pretty big control (2" high at least)
and
it
looks
terrible to have 2" of blank space at the bottom of those
first
pages...

:

Actually, you might be able to use the Page Footer section
for
what
you
seek.

You can put code in the Format event of the PageFooter
section
to
test
if
[Page]=[Pages], and use that for setting the visible
property
of
the
textboxes/controls that are to print only on the last page.

Me.ControlName.Visible = ([Page]=[Pages])

This might get you what you want more easily.

--

Ken Snell
<MS ACCESS MVP>


in
message
Sorry... I slightly misread your question. No, you're
correct
in
what
you
see.. the report footer prints after the last data record
for
the
report.
There is no built-in way to make the report footer go to
the
bottom.
You
must do it via some "tricky" programming that has to check
the
"height" of
the last page, determine the "height" of your footer,
subtract
the
two,
and calculate how much "white space" to be put into the
footer,
which
probably would be done by changing the height of the
textboxes
in
the
footer and then adding blank lines to the beginning of the
text
in
those
textboxes so that the data print at the bottom.

However, Stephen Lebans may have something already worked
out
for
this...
see his site www.lebans.com.

--

Ken Snell
<MS ACCESS MVP>


Hello Ken,
Well, I may be crazy, but I just made a report from
scratch.
I
put
3
records in the table underlying the report, and I added a
report
footer.
I'm
afraid the report footer comes right after the 3rd
record!
It
is
definitely
not at the bottom of the page. And this is the easy
case,
there
is
only
1
page in my report!

:

Use the Report Footer section for those textboxes...
this
section
prints
only at the bottom of the last page.

--

Ken Snell
<MS ACCESS MVP>

news:[email protected]...
 
You have a very poor attitude towards those who were trying to help you
with your issue. This is a peer support Newsgroup, no one is paid for
their time here.

Your issue has several solutions. Good luck finding one that works for
you.
--

Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.


Well. I know it's not a standard feature in Access.

I don't really care what is in stephan lebans' site, unless it helps me
directly with my problem.

I don't mind complicated programming, but I thought this newsgroup was here
for guidance. I AM a programmer / developer and need to get this thing done.


Is there no further escalation of this issue, or are we content with the
solution that "it's difficult"? Thanks for trying-

Ken Snell said:
As I have noted, what you seek is not straightforward nor easy -- it's not
built into ACCESS as a standard feature.

I do not have a solution already worked out. I just checked Stephen Lebans'
web site and I don't see that he has a utility to do what you seek.

It will require some complicated programming to try to do what you seek, and
you may need to hire a programmer/developer to come up with the solution for
your particular setup.

--

Ken Snell
<MS ACCESS MVP>



But I do not want to print my last section of stuff after the detail
section... I want it at the Bottom of the last page!

I included that top property in my else clause. It did not help.

:

Told you it wasn't easy < g >.

Trying to set the height property of the report footer section while in
the
page footer section probably is going to lead to problems. I also note
that
you're not setting the Top property of the Txt2 textbox in the "Else"
portion of the block.

In order for ACCESS to "generate" a report where you are using the Pages
property, it must format every page of the report in order to get a Pages
value, then it formats each page again as you print/view it. Thus, it's
possible for ACCESS to become confused, as you're seeing.

I've run across another trick that might work for you. Are you using a
grouping in the detail section? If not (or even if you are), create a new
group as the first group (Sorting and Grouping menu), and group on the
number 1. Select to have group header and footer sections. Then put your
"last page" data in that group's footer section. This section will print
only after all data have been printed in the Detail section. That also
may
do what you seek.
--

Ken Snell
<MS ACCESS MVP>





oops, I take it back. It worked fine while previewing the report on
the
screen. But it PRINTS ON THE PRINTER TOTALLY DIFFERENTLY!!
Unbelievable.
For example, instead of 5 pages it prints 6 pages. (and on the 5th
page
my
textbox even shows page 5 of 5). Here is my code:
Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount As
Integer)
If ([Page] = Pages) Then
Me.txt1.Visible = True
Me.Txt2.Visible = True
Me.PageFooterSection.Height = 3 * 1440
Me.ReportFooter.Height = 0 * 1440
Me.Txt2.Top = 1 * 1440
Else
Me.txt1.Visible = False
Me.Txt2.Visible = False
Me.PageFooterSection.Height = 0 * 1440
Me.ReportFooter.Height = 3 * 1440
End If

:

Well, now, I find that the code doesn't do what I had thought.... but
if
you
put an invisible textbox in the page footer section that uses an
expression
involving the [Pages] property (control source would be
=[Pages]
)

then it will work. Reports sometimes require a control to be on the
report
where the control uses a field that is being used in code or other
controls
or properties.

--

Ken Snell
<MS ACCESS MVP>




are you sure about this stuff? I can't even get this to work:
Private Sub PageFooterSection_Format(Cancel As Integer, FormatCount
As
Integer)

If ([Page] = [Pages]) Then
Me.Label11.Visible = True
End If
End Sub

that should turn on the visibility of the label that is in the page
footer
section... But it doesn't.

Earlier I had mixed success turning that label's visibility on and
off
(on
page 2 for example) but it doesn't seem consistent. I think I am
missing
something here.

:

Additional note....

If the label is at the top of the page footer section, changing its
height
most likely will still leave white space, as the section's height
is
not
being changed as well. You'd also need to reduce the height of the
footer
section and change the Top property of the controls that are below
that
label. (You're now seeing an example of what my first reply was
suggesting
would be involved with trying to change the location of the report
footer.)
--

Ken Snell
<MS ACCESS MVP>



message
Then change its height to zero when you make it invisible:

Select Case ([Page]=[Pages])
Case True
Me.ControlName.Visible = True
Me.ControlName.Height = 1440 * NumberOfInchesHigh
Case False
Me.ControlName.Visible = False
Me.ControlName.Height = 0
End Select

--

Ken Snell
<MS ACCESS MVP>


OK, I have just tried this. The problem with this approach is
that
the
control still wastes space on the first pages where it is not
visible.
I
can
turn the label's visibility on and off fine (making it visible
only
on
the
last page) but it is a pretty big control (2" high at least) and
it
looks
terrible to have 2" of blank space at the bottom of those first
pages...

:

Actually, you might be able to use the Page Footer section for
what
you
seek.

You can put code in the Format event of the PageFooter section
to
test
if
[Page]=[Pages], and use that for setting the visible property
of
the
textboxes/controls that are to print only on the last page.

Me.ControlName.Visible = ([Page]=[Pages])

This might get you what you want more easily.

--

Ken Snell
<MS ACCESS MVP>


message
Sorry... I slightly misread your question. No, you're correct
in
what
you
see.. the report footer prints after the last data record for
the
report.
There is no built-in way to make the report footer go to the
bottom.
You
must do it via some "tricky" programming that has to check
the
"height" of
the last page, determine the "height" of your footer,
subtract
the
two,
and calculate how much "white space" to be put into the
footer,
which
probably would be done by changing the height of the
textboxes
in
the
footer and then adding blank lines to the beginning of the
text
in
those
textboxes so that the data print at the bottom.

However, Stephen Lebans may have something already worked out
for
this...
see his site www.lebans.com.

--

Ken Snell
<MS ACCESS MVP>


Hello Ken,
Well, I may be crazy, but I just made a report from
scratch.
I
put
3
records in the table underlying the report, and I added a
report
footer.
I'm
afraid the report footer comes right after the 3rd record!
It
is
definitely
not at the bottom of the page. And this is the easy case,
there
is
only
1
page in my report!

:

Use the Report Footer section for those textboxes... this
section
prints
only at the bottom of the last page.
news:[email protected]...
 
Back
Top