Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Crystal subreports 1

Status
Not open for further replies.

Hutchine

Programmer
Feb 4, 2002
9
US
I have created a master report using Crystal 8.5 that receives the parameters then passes them to two sub-reports. The first sub-report returns information on 5 sales categories for a customer. The 2d sub-report returns information on 5 additional categories. The 2d sub-report should display under the first sub-report on the same page. As long as information on only one customer is ask for the reports work as expected. If you ask for information on more than one customer, in our case we would like information on all customers in a division; the report displays all information in the first sub-report on one page then all the information in the 2d sub-report on another page. i.e. Customer 1, first sub-report, customer 2 first sub-report then customer 1 second sub-report, customer 2 second sub-report. Is there any way to keep both sub-reports’ information for a customer together on one page.
 
Obviously if there's too much information, then you can't.

Try right clicking each subreport and selecting Format Subreport and turn off the Keep Together.

Also right click whatever sections the subreport are in and select format section and turn off the keep together.

-k
 
Dear Hutchine,

It is a function of your report design?

Is it possible to add a grouping to the main report for customer and then place the two subreports in this group?

regards,

ro

Rosemary Lieberman
rosemary@microflo.com, Microflo provides expert consulting on MagicTSD and Crystal Reports.
 
Thank you synapsevampire and rosemaryl. I have tried both things and they had no effect on the problem.
 
Dear Hutchie,

Without more information it is impossible to help.

If I create a Main Report Grouped by Field A (Division) and then by Field B (customer)

Layout:

GH1 - Divsion
GH2 - Customer
Details - Suppressed
GF2a - Subreport 1
GF2b - Subreport 2
GF1 - Total Customers for Division Summary

It is impossible for it to print the data for Customer 1 Subreport 1 and then Customer 2 Subreport 1 then Customer 1 Subreport 2 then Customer 2 Subreport 2.

All I can assume is that it is the setup of your report.

Please share the design of your report and perhaps more help could be given.

regards,
ro

Rosemary Lieberman
rosemary@microflo.com, Microflo provides expert consulting on MagicTSD and Crystal Reports.
 
I am not clear on what you want. Do you want

Cust1
Sub 1
Sub 2
Cust2
Sub 1
Sub 2
Cust3
Sub 1
Sub 2


or

Cust1 Sub1
Cust2 Sub1
Cust3 Sub1

Cust1 Sub2
Cust2 Sub2
Cust3 Sub2

 
Here is my Master report lay out (crystal 8.5):

report header suppressed
page header suppressed
group header 1 CUSTOMER
Detail suppressed
group footer 1 CUSTOMER
group footer 1 a. SubReport_a
group footer 1 b. SubReport_b
page footer suppressed
report footer suppressed

OUT PUT NOW
(In the format the page break before/after are
not checked for subreport1. It is checked for
page break after subreport2)
Subreport_a customer1
new page
Subreport_a customer2
new page
Subreport_b custorme1
new page
Subreport_b customer2
NEEDED OUT PUT
Subreport_a customer1
subreport_b customer1 (page break after is checked)
page break
subreport_a customer2
subreport_b custorme2
 
Dear Hutchine,

Aha!

You need to modify the subreport links to add Customer linking to the subreport so that the subreport only prints for the Customer in each group!

Regards,

ro

Rosemary Lieberman
rosemary@microflo.com, Microflo provides expert consulting on MagicTSD and Crystal Reports.
 
Hi rosemary
Your reply was just what I needed. It worked great.
Thank you for your support.

Ed
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top