cancel
Showing results for 
Search instead for 
Did you mean: 
SAP Community Downtime Scheduled for This Weekend

Passing value from subreport to main report

Former Member
0 Kudos
82

Post Author: dwsebert

CA Forum: Formula

In my subreport I have declared a shared numbervar = @sharetotal. In the main report I am displaying the shared number variable in the report header. I need to create another formula in the main report header that says if the value of the share is equal to zero, then TRUE, else false. No matter what value I am returning, I am always getting a FALSE evaluation. Is my issue related to when the data is evaluated?

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Post Author: Roca

CA Forum: Formula

Short Answer: Yes.

Long Answer: When passing @sharetotal from the subreport to the main report, you have to put @sharetotal AFTER its related subreport, not BEFORE. Right now, putting @sharetotal in the reportheader returns false because the related subreport has not been evaluated yet. I have tried using a series of formulas to get around this, but it doesn't work. To the best of my knowledge, there is no easy workaround.

My recommended solution: Make a second subreport and insert it into your report header.

My unrecommended solution: Search for KBase article c2011950. In the process of describing how to make a Table of Contents, it can give you an idea of how to use CR to write to your db, so that you can pull it back in later. Once set up, the user has to refresh 2 or 3 times to completely update the data.

Hope this helps!