Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Reports / Printing / December 2005

Tip: Looking for answers? Try searching our database.

How do I keep individual controls or groups together in reports

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jon22 - 03 Dec 2005 04:33 GMT
I am trying to keep the contents of a text box from splitting over two pages
in a report. I have a large amount of fields in my Report Footer and it's not
practical to set the whole Report Footer section to 'keep together' or 'force
new page' as I want it to flow on straight after the Detail section ends.
Does anyone know a way I can do this and also possibaly even keep a small
group of controls together and from appearing on different pages as well? So
in effect I have "sub-sections" in my report?

Also, I know you can limit Page Footers to appear relative to the appearance
of Report Footers & Report Headers on a page, but is there a way you can
limit your Page Footer section to only appear on a particuar page? ie. such
as limiting it to the second last page - where [Page]=([Pages]-1)

Help on any of these would be greatly appreciated
Marshall Barton - 03 Dec 2005 15:07 GMT
>I am trying to keep the contents of a text box from splitting over two pages
>in a report. I have a large amount of fields in my Report Footer and it's not
[quoted text clipped - 8 lines]
>limit your Page Footer section to only appear on a particuar page? ie. such
>as limiting it to the second last page - where [Page]=([Pages]-1)

Since there is no KeepTogether property for individual
controls, you have to use more sections where you can
specify the property.

To simulate the report footer (but not full width in
multi-column reports), you can create top level groups on a
constant expression such as =1.  You can then place your
group of controls into their own section.  Same for the long
text box.  Just don't get carried away with this because you
can only have ten group levels.

You can easily hide a page footer by making it invisible
    Me.Section(4).Visible = (Page=(Pages-1))
or using Cancel = True in its Format event.  However, this
will not make its space available for other use.

Signature

Marsh
MVP [MS Access]

Jon22 - 04 Dec 2005 04:35 GMT
Thanks for that Marsh, the info makes sense to me but I'm unsure how exactly
to apply it. Where do I actually type the expression Me.Section(4).Visible =
Page = (Pages-1) ?

And regarding the grouping, I'm unsure as to how I create the top level
groups. Does it matter that none of the controls that I'm trying to group are
linked to any fields in the underlying table? They are mainly the results of
expressions.

> >I am trying to keep the contents of a text box from splitting over two pages
> >in a report. I have a large amount of fields in my Report Footer and it's not
[quoted text clipped - 24 lines]
> or using Cancel = True in its Format event.  However, this
> will not make its space available for other use.
Marshall Barton - 04 Dec 2005 06:17 GMT
Apparently, you don't have any grouping in your report yet
;-)

Use the Sorting and Grouping window (View menu) to specify a
group.  Just enter =1 in the top row's Field/Expression and
then enter Yes in the Group Footer row in the lower part of
the window.

You can then split your controls across the group footer and
the report footer.  You may even want to add another group
using another constant expression (e.g. =2) to get a third
section.

And, No, it doesn't matter if the controls are bound or
unbound or whatever.

I don't know enough about what you have going on in your
report to be sure where you want to make the page footer
invisible, but using the page footer section's Format event
procedure is probably a safe place.
Signature

Marsh
MVP [MS Access]

>Thanks for that Marsh, the info makes sense to me but I'm unsure how exactly
>to apply it. Where do I actually type the expression Me.Section(4).Visible =
[quoted text clipped - 33 lines]
>> or using Cancel = True in its Format event.  However, this
>> will not make its space available for other use.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.