Solved

Suppress/Change Page Header on condition

Posted on 2011-09-21
4
272 Views
Last Modified: 2012-05-12
I have a report with a Sub-Report and I need to change something in the Page Header

The thing is the page number on what the header needs to change/suppress is not always the same.  Depending on the amount of data the user enters it might shift to the next page.

Attached you will see a Header with the word "Motto"

I need to change that word (This is a normal label field) to something else only on the page where I have the sub-report and anything after that should go back to the original Page Header.

So I need to Either suppress the entire page header for this page (but no page number formula will work as the page isn't always the same number) or I need to suppress this label field and un-suppress the label that I have to show.

How can I do this?
0
Comment
Question by:CuraSA
  • 2
  • 2
4 Comments
 
LVL 100

Expert Comment

by:mlmcc
ID: 36578320
Here is an idea.

You may need to change your report layout a little

Original report layout - assumes agroup with the subreport in the group footer

RH
PH
GH1
Details
GF1 - Subreport


Right click the section with the subreport in the left margin
Click INSERT SECTION BELOW
Repeat
Drag one of the new sections so it is above the one with the subreport

Now it will look like

RH
PH
GH1
Details
GF1a
GF1b - Subreport
GF1c

Add a formula to the report header
WhilePrintingRecords;
Global BooleanVar SuppressMotto;
SuppressMotto := False;
""

Add a formula to GF1a
WhilePrintingRecords;
Global BooleanVar SuppressMotto;
SuppressMotto := True;
""

Add a formula to GF1c
WhilePrintingRecords;
Global BooleanVar SuppressMotto;
SuppressMotto := False;
""

Suppress the field with
WhilePrintingRecords;
Global BooleanVar SuppressMotto;
SuppressMotto

mlmcc
0
 

Author Comment

by:CuraSA
ID: 36578752
Hi mlmcc

I made the changes to have 3 GF in my report.  I opened my section expert and pasted the above formula's in the "Suppress if blank" window.  Is this correct?

If this is correct then it doesn't work.  There's report looks the same :(
0
 
LVL 100

Accepted Solution

by:
mlmcc earned 300 total points
ID: 36580509

The suppression formula goes in the SUPPRESS of the section expert to suppress the entire page header or it should go on the suppression formula of the field itself.

mlmcc
0
 

Author Closing Comment

by:CuraSA
ID: 36903601
I ended up removing the details in the heading and made the PH a bit smaller.  Then when I needed to I created the Appendix1 ect. on the page I was working on.
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now