Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2020 : Report Design
Message Icon Topic: Subreport falls onto next page when too long Post Reply Post New Topic
Page  of 2 Next >>
Author Message
bigburb
Newbie
Newbie


Joined: 07 Oct 2009
Location: United States
Online Status: Offline
Posts: 26
Quote bigburb Replybullet Topic: Subreport falls onto next page when too long
    Posted: 05 Mar 2010 at 2:22pm
I have two subreports in my group footer. When my second subreport is too long to fit in the first page, it leaves the first page blank on and goes onto the second page. I've split the GF in to A and B, removed keep together for section and for the group, but it keeps falling onto the next page. I can't figure out what's causing this, and information on the web is scarce.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 05 Mar 2010 at 2:37pm
Right click on the Sub Report and select Properties.
On the bottom of the properties is a box for Keep obbject together.
Uncheck it.
IP IP Logged
bigburb
Newbie
Newbie


Joined: 07 Oct 2009
Location: United States
Online Status: Offline
Posts: 26
Quote bigburb Replybullet Posted: 08 Mar 2010 at 9:31am
OK that worked but now I have a new problem: If I have some kind of grouping on the subreport, the main report is only 2 pages long. However if I remove the grouping the subreport repeats for 6 pages.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 08 Mar 2010 at 9:35am

YOu mean if you remove grouping  in the main report? You placed the Sub-report onto the details section then, correct? If so it will reun the subreport for every time the detail section in the main report is used.

Move it from Details section to a report header or footer (in the main report).
IP IP Logged
bigburb
Newbie
Newbie


Joined: 07 Oct 2009
Location: United States
Online Status: Offline
Posts: 26
Quote bigburb Replybullet Posted: 08 Mar 2010 at 9:49am
If I remove grouping in the subreport it repeats in the main report. The subreport is in GH5b in the main report.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 08 Mar 2010 at 9:51am
Are you linking the sub report to the main report?
If so on what field(s)? Were these the fields you had grouped on in the sub-report?
IP IP Logged
bigburb
Newbie
Newbie


Joined: 07 Oct 2009
Location: United States
Online Status: Offline
Posts: 26
Quote bigburb Replybullet Posted: 08 Mar 2010 at 11:05am
The sub is linked in by CO number, CO line, and CO release.   The sub is grouped by job suffix.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 08 Mar 2010 at 12:12pm

one guess,

in the sub report are you using more than 1 table?
If so was the only field used from one of those tables the job-suffix field for the grouping?
If so go into the subreport edit mode, open Datbase Expert, Links Tab, Double click on the link and change your Enforce from NOt Enforced to Enforced Both
IP IP Logged
bigburb
Newbie
Newbie


Joined: 07 Oct 2009
Location: United States
Online Status: Offline
Posts: 26
Quote bigburb Replybullet Posted: 08 Mar 2010 at 2:04pm
Worked beautifully... what exactly does changing the enforce method do?
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 08 Mar 2010 at 2:18pm
I am really surprised we figured that one out...Shocked
 
(very oddly IMO) In Crystal within the Database Expert making a join between tables (or views or whatever) does not make the join "function". If you use any field from both tables the join will now "function" (or become enforced). You can use the fields in any part of the report not just displaying in the canvas (like in the select expert or a formula or grouping or a conditionalal formula) to 'enforce' the join.
If you are only using a field from 1 table but joining to another table you have to use the 'Enforce Joins' options in Crystal.
 
In SQL (and most other systems) just making the join "enforces" it so those options never made sense to me. But this is Crystal not SQL.
 
Anyway it does not come up too often as usually designers need at least one value from both tables so it often is moot (and makes it look as if Crystal automatically enforces the join).
It is the weirdest thing to watch and can really trip up your data results.
 
You can watch it in your report.
Cahange it back to Not Enforced.
Go into the Preview Mode.
See how it is too many pages.
Now take any field from the 'unused' table and drop it on the canvas. The report will shrink as it is now 'enforcing' the joins becasue you used a field from both tables.
 


Edited by DBlank - 08 Mar 2010 at 2:42pm
IP IP Logged
Page  of 2 Next >>
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.