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

Group Suppression

Status
Not open for further replies.

Ragnarox

Programmer
Oct 2, 2003
141
US
Hello all,

I am probably missing something very obvious but i can not see it. I am trying to supress a Group Header iff all 3 details sections are supressed. Is this possible? If it is how can i accomplish this?



Any help, as always, is greatly appreciated.

Brian
 
Why would you want to supress the group rather than exclude it from the report entirely?

Click on report, edit selection formula, group and enter a formula to get rid of the desired group(s). Or better yet, get rid of the records that make up the groups by clicking on report, edit selection formula, record.

Software Sales, Training, Implementation and Support for Macola, eSynergy, and Crystal Reports
 
dgillz,

I would love to do that but unfortunately i am unable to. The one thing i forgot to mention in my initial posting is that I have a sub-report in each of the 3 detail section. In order to get the info from the sub-reports i need the item from the group header. That is why i am wanting to supress the group header if all the detail sections are supressed.

Hope this clears things up.

Any help, as always, is greatly appreciated.

Brian
 
Not knowing what version you have but in Crystal 8.5, I've been able to do the following.

Insert another group header section and move it above the group header you currently have.

Create a copy of the 3 subreports you have and strip it down to it's bare minimum or at least to whatever you link is.

Create a shared variable in the subreport

Code:
shared booleanvar sr1 := false;

if isnull({table.field}) then sr1 := true

Repeat the above for subreport 2 and 3

Make the subreports as small as possible along with the group header section.

In the main report section expert for the group header, suppress the section and click on x+2 and enter


Code:
shared booleanvar sr1;
shared booleanvar sr2;
shared booleanvar sr3;

sr1 and sxr2 and sr3


This will also allow you to conditionally suppress detail section using the shared variable.

-LW
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top