Subreport group headers

G

Guest

Dear All,

I have a main report with three subreports in the detail section. In certain
circumstances I don't get the column headings printed on a new page
(sometimes multiple pages per main record). Each subreport has a report
header, group header (group is =1), detail and a report footer.

When the subreport header and group header appear at the bottom of the page
(with no detail) the group header doesn't appear on following page. Any other
situation it does appear (as I would expect). And in one example I have seen
it printed half on one page and half on the next?

The settings I currently have:
Main report detail section - Keep together = No
Can grow = Yes
Shrink = no

Subreport settings
Report header - keep together = yes
grow & shrink = No

Subreport group header
keep together = yes
grow / shrink = no
repeat section = yes

I suspect something is broke. Can anyone validate my settings and let me
know if they are right or wrong?

Access 2002 SP3
Win2k SP4

Thanks in advance,

Terry
 
M

Marshall Barton

TerryC said:
I have a main report with three subreports in the detail section. In certain
circumstances I don't get the column headings printed on a new page
(sometimes multiple pages per main record). Each subreport has a report
header, group header (group is =1), detail and a report footer.

When the subreport header and group header appear at the bottom of the page
(with no detail) the group header doesn't appear on following page. Any other
situation it does appear (as I would expect). And in one example I have seen
it printed half on one page and half on the next?

The settings I currently have:
Main report detail section - Keep together = No
Can grow = Yes
Shrink = no

Subreport settings
Report header - keep together = yes
grow & shrink = No

Subreport group header
keep together = yes
grow / shrink = no
repeat section = yes

I suspect something is broke. Can anyone validate my settings and let me
know if they are right or wrong?

Access 2002 SP3
Win2k SP4


You should never get part of a line on one page and part on
the next page. I don't know for sure, but it sounds like
there's a problem with the printer driver.

The one suggestion I have it to try setting the group's (not
a section's) KeepTogether property to With First Detail (in
the Sorting and Grouping window).
 
G

Guest

Marshall,

Thanks for your response.

Sorry I didn't include the grouping stuff in the original posting.

It is set up to:
header / Footer =yes
group on = each value
interval = 1
Keep together = with first detail

Where I said it printed half on one page and half on the next I meant that
line 1 of the header on one page and line 2 on the next page. This problem
exhibits on 4 different printers and also on the Adobe pdf print driver ....
?

If detail lines print to the bottom of the page the header prints as
expected at the top of the next page for the following details. It appears
that when the subreport's report and group header appear at the bottom of a
page (or span the end of page / start of next page) that a problem occurs.

Any suggestions or anything else I can try.

Thanks again,

Terry
PS there is some code executing in the main report's page header "on format"
event. Could this be interfering???? The code is to number the group's pages
1 of 3, 2 of 3 and 3 of 3. I used the code from this link as the basis for
this: http://www.mvps.org/access/reports/rpt0013.htm
 
M

Marshall Barton

It sure looks like you have all the appropriate KeepTogether
settings correct and I don't think that code should intefere
with this.

I have never seen this kind of thing and am at a loss as to
why KeepTogether is not working for you.

One last straw to grasp at here is if there is any code (in
the subreport?) that is changing the setting of a
KeepTogether property. There are some situations where
turning a property off once turns it off for the entire
report (subreport?)
 
G

Guest

Thanks Marshall. I'll keep playing with different ideas and will post back
when (if) I get it working cleanly. I will probably find there is something I
am doing that I forgot about that is messing my report about. Anyway .....
back to report writing.

Thanks for your input, it was a help just to have my settings confirmed as
probably OK.

Thanks again,

Terry

Marshall Barton said:
It sure looks like you have all the appropriate KeepTogether
settings correct and I don't think that code should intefere
with this.

I have never seen this kind of thing and am at a loss as to
why KeepTogether is not working for you.

One last straw to grasp at here is if there is any code (in
the subreport?) that is changing the setting of a
KeepTogether property. There are some situations where
turning a property off once turns it off for the entire
report (subreport?)
--
Marsh
MVP [MS Access]

Sorry I didn't include the grouping stuff in the original posting.

It is set up to:
header / Footer =yes
group on = each value
interval = 1
Keep together = with first detail

Where I said it printed half on one page and half on the next I meant that
line 1 of the header on one page and line 2 on the next page. This problem
exhibits on 4 different printers and also on the Adobe pdf print driver ....
?

If detail lines print to the bottom of the page the header prints as
expected at the top of the next page for the following details. It appears
that when the subreport's report and group header appear at the bottom of a
page (or span the end of page / start of next page) that a problem occurs.

PS there is some code executing in the main report's page header "on format"
event. Could this be interfering???? The code is to number the group's pages
1 of 3, 2 of 3 and 3 of 3. I used the code from this link as the basis for
this: http://www.mvps.org/access/reports/rpt0013.htm
 

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