Displaying Suppressed Group Header On New Page

I apologize if this is long winded in advance. I’m new to Crystal Reports so I wanted to lay this out as clear as possible being I’m not familiar with all of the terminology yet.

I was tasked with modifying a company’s existing report in Crystal. They have trade data in a report that is in a Group Header / Details / Group Footer layout. They want 3 of the fields in the group header displayed only for the first row in a grouping and then hidden in the rest of the grouping. The problem is they want those values displayed again if the grouping details carries over to a new page - they would like those 3 fields’ values displayed again in the top row.

I’ve been able to get the data suppressed successfully on a single page using the below suppress formula for the specified field in the grouping:

IF(PREVIOUS({Field_1}) = {Field_1}) THEN TRUE ELSE FALSE

This works exactly how they need it to until the data carries over to a new page. How can I get these displayed again for the same grouping in the top row of a new page?

Note: I’ve already tried using “Repeat Group Header On Each Page” option in Change Group --> Options for the Group Header to no success. I also tried doing the Format Field --> Suppress/Suppress If Duplicated option on the specified fields, also, to no success.

A sample of the expected results outline of the report would look like:

Field 1 Field 2 Field 3 Field 4 Field 5


value a value b value c value d value e
------------------ value f value g value h
------------------ value i value j value k (grouping 1 data)

(new page)

value a value b value l value m value n
------------------ value o value p value q (grouping 1 data)

value c value d value a value b value c
------------------ value d value e value f
------------------ value g value h value i (grouping 2 data)

Thanks in advance for any help any of you are able to provide! If I can get this one solved it’d be a huge weight off my shoulders!


DannyS0801 (BOB member since 2016-02-05)

Hi Danny,

We normally get this type of issues and most of them will solve with repeat group header on each page. But in few cases due to space problems at end of the page or detail section not moving to next page it won’t work as expected.
For detail debugging you need to write a formula and place in each section and see what is happining. first in detail write
Shared NumberVar a;
a:=a+1;
a;
and display this formula in detail section as each record will increase by one value like 1,2,3,4,5,6,7,8
now try to create one more formula as below
shared NumberVar a;
a:=0;
a;
and place this formula in group footer to see whether this value is resetting in group footer or not.
now put another formula in group header as below
Shared NumberVar a;
a;
It will just display the value of A that means that group is completed or not… and place same formula in page header and see what are the values getting from this shared variable.

If you have multiple groups then use multiple formulas with sharedvariable name as b and c also and put in different detail or in same detail section and try to reset each shared variable in each group and then place these formulas in group headers and page headers. After checking all these numbers you will definitely get idea what need to suppress.
in suppress condition of particular section you can use this shared variable like
shared numbervar a;
a=1
that means if value is 1 in a it will suppress… that means normally when group completes a will become zero so based on that value you can display… if that group itself not displaying in next page put the same values or fields in page header as group header and suppress group or page based on shared variable… You will definitely get required result with this method… we solved many problems with this technique.


surya.g :india: (BOB member since 2009-11-24)