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

Passing a Shared Variable from a Subreport

Status
Not open for further replies.

kvena

Technical User
Aug 5, 2005
19
US
I passed a shared variable from a subreport to the main report. The shared varialbe is working correctly but I am not having success in getting my row to supress based on the value of the shared variable. I am using Crystal 8.5.

 
The subreport must be in a section above the one you want suppressed using the shared variable.

-LB
 
I have the subreport in my Group Header and @Total (my shared variable formula) in the Group Footer.
 
You neglected to say what section you want suppressed.

-LB
 
The section I want supressed is in Group Header #1e. The subreport is in Group Header #2e. The shared variable is in Group Footer #1b.
 
The shared variable must be displaying the value from the previous subreport, since you have the shared variable positioned before the subreport which is creating the shared variable.

The shared variable must be displayed in a section below the one in which the subreport is executing, e.g., GH#2f. You should also have a formula in the main report in GF#2 that resets the shared variable, as in:

whileprintingrecords;
shared numbervar x := 0;

Note that to suppress the same section that you have placed the subreport in, you would have to add the subreport again in a section above GH#2e, e.g., Gh#2d, so that the shared variable could be used for suppression.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top