Crystal Reports How do I suppress all pages except report footer when page number is being reset by group?

Crystal Reports XI
 I have a report in which I would like to suppress all sections except for the Report Footer on the last page.  The report footer consists of summary totals.  The report itself consists of a mailable letter that can be 1 or more pages (successive pages are different than the first page of each group).  It is grouped by CompanyID and the page number is being reset (intentionally) after every group change.  

I have checked numerous posts and have not yet found one that helps me.  Since I am already conditionally suppressing page 1 or page 2 of letter, I would need something that would work in tandem with this suppression.  

Thank you in advance for your help!
Who is Participating?
jdg556Connect With a Mentor Commented:
I think I got something for you.

make the following formula called "footer":

global numbervar rank; 
global numbervar rank2; 
global numbervar rank3; 

rank2 := rank ;
rank := rank + 1;
if OnLastRecord then rank := rank + 1000;
rank3 := rank-rank2;

Open in new window

then add in your section expert the supress variables like:
Page Header b: I supress when PageNumber = 1 or {@footer} > 1

Hope this helps!
I don't follow what you want.

If you want all sections suppressed just suppress them.

What would you like to show and what not?

You can supress all sections except report footer or do you mean all page footer except the last page?
Then go to the section expert > page footer, tab the supress tab and press the X-2 button next to supress and enter "Not OnLastRecord"

If this doesn't help please clarify yourself.
Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

mctwftechAuthor Commented:
What I need to do is suppress everything but the report footer when I print the last page of the report.  OnLastRecord suppresses pageheader a on the last record also which in this case is also the page before the report footer.  

Page header a;  I suppress when PageNumber > 1
Page Header b: I supress when PageNumber = 1

When I added the report Footer (to be only printed at the end), it prints on a new page but PageHeader A (which is a letter form) also prints with the Footer with the same data as the page before.

I can't use Total pages because I reset the page number with the group.

Does this help at all?
mctwftechAuthor Commented:
jdq556, you are a genius.  Works like a charm.  
mctwftechAuthor Commented:
thank you so much.  You are a genius!   Works like a charm!
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.