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

Suppressing Page-Footer 2

Status
Not open for further replies.

JohnBurmester

Programmer
Nov 19, 2002
12
DE
Hi.

I'm new to Crystal Reports so I appreciate your patience.

I have the following problem:

In a group I have two group footers 1a and 1b which will be printed on different pages (pagebreak after footer 1a). The first page (or several) which contains most of the report and group footer 1a should be printed with a page footer. The second page containing group footer 1b should be printed without the page footer.

How can I do this?

Thanks.
John.
 
First, create some formula value that will be set when group 1 is finished

Then right-click on the footer. Select [Format Section], and the formual (x-2) for Suppress. Test the formula so that it suppresses once group 1 has been done.

Suppress can also check page numbers, but in your case this would not work since the number of pages is variably, if I've understood you rightly. Madawc Williams
East Anglia
Great Britain
 
Thanks for the reply.

Sorry for being so new, but how do I create a formula that will be set when group 1 is finished? And how do I reset it then?

Can you point me towards a crystal guide on formulas worth reading?

Thank's so much.
John
 
You can put it in the group footer, something like that. Supressed fields and sections still influence logic

As for guides, I mostly learned just doing Crystal, trial and a lot of error. Madawc Williams
East Anglia
Great Britain
 
John,

Forumla writing takes practice, it always helps to look at other peoples formuals as much as possible and to make use of this forum.

I notice that ken hamady has just published a forumla guide on his web page and although I haven't looked at it, with Ken's experience I'm sure it's worth buying (about 35 US dollars).

For your problem, you need to create 2 formulas:

Forumla 1: @TurnPF_On
Code:
 WhilePrintingRecords;
 BooleanVar PF_On := True;

Forumla 2: @TurnPF_Off
Code:
 WhilePrintingRecords;
 BooleanVar PF_On := False;

Place formula 1 in the GF1a section (you can supress the object so it doesn't show in the report)

Place formula 2 in the GH1b section

Format the page footer to be supressed if:
Code:
 WhilePrintingRecord;
 BooleanVar PF_On;
 PF_On = False

I am assuming you have a page throw after GF1b (in particular, you should never have another Group 1 header and footer on the same page as GF1b). Steve Phillips, Crystal Consultant
 
Hi!

I just wanted to warn you of an 'error' that may occur when you suppress a page footer.

The following is taken from the CrystalDescisions site:


"Conditionally suppressing the page footer in a report will print a blank space that is the equivalent size of the page footer being suppressed. The blank space printed in CR is by design."

They go on to suggest a work-around (which didn't work for me, but may be OK for you if you need it)



I had trouble with this problem when I was designing a report that was to be printed on continuous stationery.
Just so that you are aware of it - You aren't going mad if this happens to you!
 
Hi to All.

Thanks for the great help. I really appreciate this. However the customer decided to have pagefooters on all pages now, so I guess it was a good learning experience.

BW,
John
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top