473,396 Members | 2,111 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Section keep-together within subreport?

I tried to fix a problem for a client today in which report sections and even
individual text controls in some of their reports are being split across page
boundaries. Of course, I was thinking the answer was just going to be setting
some Keep Together properties to Yes. Alas, it was not to be.

It turns out that the report in question is actually a combination of 2 other
reports based on different tables. The reports should follow one after the
other with a small gap even if it is in the middle of a page, so the only easy
way to merge them seems to be making them both subreports of a singe master
report. That's all fine except it turns out section Keep Together properties
within subreports are simply ignored.

Next, I tried experimenting with the print control properties in the Format
event handlers, but it turns out these don't work as expected in subreports
either. The Top property does not change from one Format event to the next,
even though I say to advance to the next position, so my code goes into an
endless loop.

Finally, I ended up telling the client that I cannot see that there is any
quick fix for this, and the best solution is probably to use Word automation
to generate the output (which adds some business value for them anyway). I
thought I'd put out a message here though, and see if anyone knows a less
extreme solution.
Nov 13 '05 #1
6 8604
The Keep Together property works in both the detail and group sections. You
could create a group with blank header, and place your subreport in the
group footer. If I understand you correctly, I have similar setups of such
reports with the subreport in the main's report footer.
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:ie********************************@4ax.com...
I tried to fix a problem for a client today in which report sections and
even
individual text controls in some of their reports are being split across
page
boundaries. Of course, I was thinking the answer was just going to be
setting
some Keep Together properties to Yes. Alas, it was not to be.

It turns out that the report in question is actually a combination of 2
other
reports based on different tables. The reports should follow one after
the
other with a small gap even if it is in the middle of a page, so the only
easy
way to merge them seems to be making them both subreports of a singe
master
report. That's all fine except it turns out section Keep Together
properties
within subreports are simply ignored.

Next, I tried experimenting with the print control properties in the
Format
event handlers, but it turns out these don't work as expected in
subreports
either. The Top property does not change from one Format event to the
next,
even though I say to advance to the next position, so my code goes into an
endless loop.

Finally, I ended up telling the client that I cannot see that there is any
quick fix for this, and the best solution is probably to use Word
automation
to generate the output (which adds some business value for them anyway).
I
thought I'd put out a message here though, and see if anyone knows a less
extreme solution.

Nov 13 '05 #2
I don't think you are understanding me correctly. Each subreport may span
multiple pages of the master report. Within each subreport, I want each
section kept together. The Keep Together properties of sections in the
subreport are having no effect whatsoever in any type of section.

On Thu, 17 Feb 2005 13:44:59 GMT, "Ed Robichaud" <ed*********@wdn.com> wrote:
The Keep Together property works in both the detail and group sections. You
could create a group with blank header, and place your subreport in the
group footer. If I understand you correctly, I have similar setups of such
reports with the subreport in the main's report footer.
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:ie********************************@4ax.com.. .
I tried to fix a problem for a client today in which report sections and
even
individual text controls in some of their reports are being split across
page
boundaries. Of course, I was thinking the answer was just going to be
setting
some Keep Together properties to Yes. Alas, it was not to be.

It turns out that the report in question is actually a combination of 2
other
reports based on different tables. The reports should follow one after
the
other with a small gap even if it is in the middle of a page, so the only
easy
way to merge them seems to be making them both subreports of a singe
master
report. That's all fine except it turns out section Keep Together
properties
within subreports are simply ignored.

Next, I tried experimenting with the print control properties in the
Format
event handlers, but it turns out these don't work as expected in
subreports
either. The Top property does not change from one Format event to the
next,
even though I say to advance to the next position, so my code goes into an
endless loop.

Finally, I ended up telling the client that I cannot see that there is any
quick fix for this, and the best solution is probably to use Word
automation
to generate the output (which adds some business value for them anyway).
I
thought I'd put out a message here though, and see if anyone knows a less
extreme solution.


Nov 13 '05 #3
That's what I understood. I've retested that set-up:

main report
sub-report (with 2 groups) in report footer of main report

and the keep together grouping of the sub-report works fine (no broken
sections over multiple pages). Sure that you have the right properties set?
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:sd********************************@4ax.com...
I don't think you are understanding me correctly. Each subreport may span
multiple pages of the master report. Within each subreport, I want each
section kept together. The Keep Together properties of sections in the
subreport are having no effect whatsoever in any type of section.

On Thu, 17 Feb 2005 13:44:59 GMT, "Ed Robichaud" <ed*********@wdn.com>
wrote:
The Keep Together property works in both the detail and group sections.
You
could create a group with blank header, and place your subreport in the
group footer. If I understand you correctly, I have similar setups of
such
reports with the subreport in the main's report footer.
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:ie********************************@4ax.com. ..
I tried to fix a problem for a client today in which report sections and
even
individual text controls in some of their reports are being split across
page
boundaries. Of course, I was thinking the answer was just going to be
setting
some Keep Together properties to Yes. Alas, it was not to be.

It turns out that the report in question is actually a combination of 2
other
reports based on different tables. The reports should follow one after
the
other with a small gap even if it is in the middle of a page, so the
only
easy
way to merge them seems to be making them both subreports of a singe
master
report. That's all fine except it turns out section Keep Together
properties
within subreports are simply ignored.

Next, I tried experimenting with the print control properties in the
Format
event handlers, but it turns out these don't work as expected in
subreports
either. The Top property does not change from one Format event to the
next,
even though I say to advance to the next position, so my code goes into
an
endless loop.

Finally, I ended up telling the client that I cannot see that there is
any
quick fix for this, and the best solution is probably to use Word
automation
to generate the output (which adds some business value for them anyway).
I
thought I'd put out a message here though, and see if anyone knows a
less
extreme solution.

Nov 13 '05 #4
Odd - I just dupicated your results in a new custom report on one of my own
databases. I wonder why it's not working for the client's database?

One thing I remember that was unusual about their report is that the subreport
contians another subrport in a group header. I think it may have been that
section that was splitting across a page boundary.

On Thu, 17 Feb 2005 18:33:25 GMT, "Ed Robichaud" <ed*********@wdn.com> wrote:
That's what I understood. I've retested that set-up:

main report
sub-report (with 2 groups) in report footer of main report

and the keep together grouping of the sub-report works fine (no broken
sections over multiple pages). Sure that you have the right properties set?
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:sd********************************@4ax.com.. .
I don't think you are understanding me correctly. Each subreport may span
multiple pages of the master report. Within each subreport, I want each
section kept together. The Keep Together properties of sections in the
subreport are having no effect whatsoever in any type of section.

On Thu, 17 Feb 2005 13:44:59 GMT, "Ed Robichaud" <ed*********@wdn.com>
wrote:
The Keep Together property works in both the detail and group sections.
You
could create a group with blank header, and place your subreport in the
group footer. If I understand you correctly, I have similar setups of
such
reports with the subreport in the main's report footer.
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:ie********************************@4ax.com ...
I tried to fix a problem for a client today in which report sections and
even
individual text controls in some of their reports are being split across
page
boundaries. Of course, I was thinking the answer was just going to be
setting
some Keep Together properties to Yes. Alas, it was not to be.

It turns out that the report in question is actually a combination of 2
other
reports based on different tables. The reports should follow one after
the
other with a small gap even if it is in the middle of a page, so the
only
easy
way to merge them seems to be making them both subreports of a singe
master
report. That's all fine except it turns out section Keep Together
properties
within subreports are simply ignored.

Next, I tried experimenting with the print control properties in the
Format
event handlers, but it turns out these don't work as expected in
subreports
either. The Top property does not change from one Format event to the
next,
even though I say to advance to the next position, so my code goes into
an
endless loop.

Finally, I ended up telling the client that I cannot see that there is
any
quick fix for this, and the best solution is probably to use Word
automation
to generate the output (which adds some business value for them anyway).
I
thought I'd put out a message here though, and see if anyone knows a
less
extreme solution.


Nov 13 '05 #5
I just successfully duplicated the symptom in a new database, and my guess was
on the right track in the previous post.

If the first section in a subreport (A) can grow and contains another
subreport (B) that can grow, the Keep Together property of the first instance
of the section in subreport (A) is ignored, and the section gets cut in 2 if
it wraps over the end of a page.

The solution that seems to be working is to add another dummy grouping on =1
to the subreport with a 1-twip high header. With that in place, I'm no longer
able to cause the symptom in which first real section gets split across the
page boundary (in my test database - we'll see about the client's database).

On Thu, 17 Feb 2005 10:58:39 -0800, Steve Jorgensen <no****@nospam.nospam>
wrote:
Odd - I just dupicated your results in a new custom report on one of my own
databases. I wonder why it's not working for the client's database?

One thing I remember that was unusual about their report is that the subreport
contains another subrport in a group header. I think it may have been that
section that was splitting across a page boundary.

On Thu, 17 Feb 2005 18:33:25 GMT, "Ed Robichaud" <ed*********@wdn.com> wrote:
That's what I understood. I've retested that set-up:

main report
sub-report (with 2 groups) in report footer of main report

and the keep together grouping of the sub-report works fine (no broken
sections over multiple pages). Sure that you have the right properties set?
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:sd********************************@4ax.com. ..
I don't think you are understanding me correctly. Each subreport may span
multiple pages of the master report. Within each subreport, I want each
section kept together. The Keep Together properties of sections in the
subreport are having no effect whatsoever in any type of section.

On Thu, 17 Feb 2005 13:44:59 GMT, "Ed Robichaud" <ed*********@wdn.com>
wrote:

The Keep Together property works in both the detail and group sections.
You
could create a group with blank header, and place your subreport in the
group footer. If I understand you correctly, I have similar setups of
such
reports with the subreport in the main's report footer.
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:ie********************************@4ax.co m...
>I tried to fix a problem for a client today in which report sections and
>even
> individual text controls in some of their reports are being split across
> page
> boundaries. Of course, I was thinking the answer was just going to be
> setting
> some Keep Together properties to Yes. Alas, it was not to be.
>
> It turns out that the report in question is actually a combination of 2
> other
> reports based on different tables. The reports should follow one after
> the
> other with a small gap even if it is in the middle of a page, so the
> only
> easy
> way to merge them seems to be making them both subreports of a singe
> master
> report. That's all fine except it turns out section Keep Together
> properties
> within subreports are simply ignored.
>
> Next, I tried experimenting with the print control properties in the
> Format
> event handlers, but it turns out these don't work as expected in
> subreports
> either. The Top property does not change from one Format event to the
> next,
> even though I say to advance to the next position, so my code goes into
> an
> endless loop.
>
> Finally, I ended up telling the client that I cannot see that there is
> any
> quick fix for this, and the best solution is probably to use Word
> automation
> to generate the output (which adds some business value for them anyway).
> I
> thought I'd put out a message here though, and see if anyone knows a
> less
> extreme solution.


Nov 13 '05 #6
Thanks for posting back your trouble-shooting and solution. It may help a
lot of folks (including me).
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:51********************************@4ax.com...
I just successfully duplicated the symptom in a new database, and my guess
was
on the right track in the previous post.

If the first section in a subreport (A) can grow and contains another
subreport (B) that can grow, the Keep Together property of the first
instance
of the section in subreport (A) is ignored, and the section gets cut in 2
if
it wraps over the end of a page.

The solution that seems to be working is to add another dummy grouping on
=1
to the subreport with a 1-twip high header. With that in place, I'm no
longer
able to cause the symptom in which first real section gets split across
the
page boundary (in my test database - we'll see about the client's
database).

On Thu, 17 Feb 2005 10:58:39 -0800, Steve Jorgensen <no****@nospam.nospam>
wrote:
Odd - I just dupicated your results in a new custom report on one of my
own
databases. I wonder why it's not working for the client's database?

One thing I remember that was unusual about their report is that the
subreport
contains another subrport in a group header. I think it may have been
that
section that was splitting across a page boundary.

On Thu, 17 Feb 2005 18:33:25 GMT, "Ed Robichaud" <ed*********@wdn.com>
wrote:
That's what I understood. I've retested that set-up:

main report
sub-report (with 2 groups) in report footer of main report

and the keep together grouping of the sub-report works fine (no broken
sections over multiple pages). Sure that you have the right properties
set?
-Ed

"Steve Jorgensen" <no****@nospam.nospam> wrote in message
news:sd********************************@4ax.com ...
I don't think you are understanding me correctly. Each subreport may
span
multiple pages of the master report. Within each subreport, I want
each
section kept together. The Keep Together properties of sections in the
subreport are having no effect whatsoever in any type of section.

On Thu, 17 Feb 2005 13:44:59 GMT, "Ed Robichaud" <ed*********@wdn.com>
wrote:

>The Keep Together property works in both the detail and group sections.
>You
>could create a group with blank header, and place your subreport in the
>group footer. If I understand you correctly, I have similar setups of
>such
>reports with the subreport in the main's report footer.
>-Ed
>
>"Steve Jorgensen" <no****@nospam.nospam> wrote in message
>news:ie********************************@4ax.c om...
>>I tried to fix a problem for a client today in which report sections
>>and
>>even
>> individual text controls in some of their reports are being split
>> across
>> page
>> boundaries. Of course, I was thinking the answer was just going to
>> be
>> setting
>> some Keep Together properties to Yes. Alas, it was not to be.
>>
>> It turns out that the report in question is actually a combination of
>> 2
>> other
>> reports based on different tables. The reports should follow one
>> after
>> the
>> other with a small gap even if it is in the middle of a page, so the
>> only
>> easy
>> way to merge them seems to be making them both subreports of a singe
>> master
>> report. That's all fine except it turns out section Keep Together
>> properties
>> within subreports are simply ignored.
>>
>> Next, I tried experimenting with the print control properties in the
>> Format
>> event handlers, but it turns out these don't work as expected in
>> subreports
>> either. The Top property does not change from one Format event to
>> the
>> next,
>> even though I say to advance to the next position, so my code goes
>> into
>> an
>> endless loop.
>>
>> Finally, I ended up telling the client that I cannot see that there
>> is
>> any
>> quick fix for this, and the best solution is probably to use Word
>> automation
>> to generate the output (which adds some business value for them
>> anyway).
>> I
>> thought I'd put out a message here though, and see if anyone knows a
>> less
>> extreme solution.
>

Nov 13 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Martin Lucas-Smith | last post by:
Is there any need to keep the final break in a switch which uses a default at the end? I.e: switch ($data) { case 'foo': # Action break;
2
by: David P. Jessup | last post by:
I am wondering if I am attempting the impossible on one page. CODE: set current= cConn.Execute(SQLCurrent) Do Until current.eof Response.Write "<p>Current Path: <b>" & current("CPath") &...
2
by: ~K | last post by:
I have 3 Oracle servers that I would like to keep in sync. Only one is used as my production, the other is a backup and the third is used for development purposes. In case my primary Oracle server...
5
by: | last post by:
I'm trying to store something like this in my web.config file: <authInfoGroup> <authInfo UserId="uid1" Passport="pwd1" Expiry="" /> <authInfo UserId="uid2" Passport="pwd2" Expiry="" />...
29
by: zoltan | last post by:
Hi, The scenario is like this : struct ns_rr { const u_char* rdata; }; The rdata field contains some fields such as :
10
by: Ryan | last post by:
I've created a custom configuration section that inherits (naturally) from System.Configuration.ConfigurationSection. The configuration section is working 99% fine, however I keep coming across a...
5
by: arnuld | last post by:
it compiles without any trouble but produces "Segmentation Fault" when i try to run it. since i am at chapter 2 so my knowledge of arrays is limited to chapter 1: -------------------------...
0
by: a | last post by:
hallo also some vb language question here (but from the vb ng no answer) the htm file created by WVD 2005 has an its own encoding by code (vb net) I need to open it inoculate some text...
8
by: shapper | last post by:
Hello, I am getting the AppSettings section as follows: AppSettingsSection appSettingSection = (AppSettingsSection)ConfigurationManager.GetSection("appSettings"); However, I am getting the...
3
by: Gary Bailey | last post by:
how do I keep the information in the footer section of a access report from expanding when the detail section changes? The information in the detail section is description for an invoice. It could...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.