Shared variables values are missing in OnDemand subreport
- Crystal Reports 2008
- SAP Crystal Reports 2011
Reproducing the Issue
- Create report with an OnDemand subreport
- Create a shared variable formula in the main report and assign a value to the variable
- Create the same shared variable formula in the subreport to display the value
- Refresh the report and observe the value in the subreport. It could be missing.
Shared variables are not intended to work with OnDemand subreports.
Values could not be shared from the OnDemand subreport to the main report until the subreport got executed.
So the only direction values could be passed is from the main report to the subreport, but why to use shared variables if subreport link can do it more effective.
Use Subreport links to pass values from the main report to a subreport
WhilePrintingRecords, empty, blank, , KBA , BI-RA-CR , Crystal Reports designer or BusinessViews Manager , BI-RA-CRE , Crystal Reports for Enterprise , How To