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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Issues with Page Titles and Sub Reports 1

Status
Not open for further replies.

Nice99

Technical User
Feb 13, 2011
17
US
Hi all,

I am using Crystal Reports 2008 against Oracle database 10g:

There are 5 sub reports in the report, one sub report inserted in the Group Footer, two sub reports inserted in the Page Header b (sub1_title) and Page Header c (sub2_title), two sub reports inserted in the Report Footer a (sub1.rpt) and Report Footer b (sub2.rpt), I have checked 'New Page Afer' for Report Footer a and Report Footer b:

The structure of report:

Page Header a: texts and data fields, etc.
Page Header b: sub report - sub1_title
Page Header c: sub report - sub2_title
Group Footer #1: sub report – details data
Report Foot a: sub report – summary 1
Report Foot b: sub report – summary 2

There is no problem for Page Header a show Title for details data pages, I have difficulty to make Page Header b show Title for summary 1 sub report and Page header c show Title for summary 2 sub report, is there anyone can help? Thanks!

Nice99
 
Why wouldn't you simply add the titles to the subreports? Do the report footer subs run for multiple pages?

-LB
 
LB,

Thanks for your response!

I have tried, but all page titles contain a SQL statement with calculations; it cannot add those SQL together and run the report, and the sub report cannot insert another sub report in side of the sub report that is why I have different sub reports inserted into the Page Headers and Report Footers.

Nice99
 
Create these formulas in the field explorer->formulas->new (suppress all formulas):

//{@true1} to be placed in the (main) report header AND in
Report Footer_b;
whileprintingrecords;
booleanvar flag1 := true;

//{@false1} to be placed in Report Footer_a :
whileprintingrecords;
booleanvar flag1 := false;

//{@true2} to be placed in the (main) report header;
whileprintingrecords;
booleanvar flag2 := true;

//{@false2} to be placed in Report Footer_b :
whileprintingrecords;
booleanvar flag2 := false;

Then go into the main report section expert->page header_b->x+2 and enter:

whileprintingrecords;
booleanvar flag1;
flag1 = true //note no colon

Then select page header_c->x+2 and enter:

whileprintingrecords;
booleanvar flag2;
flag2 = true //note no colon

-LB
 
LB,

Thank you so much for your help, the report looks much better, the Page Header b and Page Header c show up correctly for Report Footer a and Report Footer b

BUT only one issue: Page Header a show up all time for other two sub reports, any way to suppress?

Nice99
 
I thought you wanted it to always show. Use a suppression formula on page header_a like this:

whileprintingrecords;
booleanvar flag1;
booleanvar flag2;
flag1 = false or
flag2 = false //note no colon

-LB
 
LB,

The formulas work great! Thank you so much for your help!!!

Nice99
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top