[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 707
  • Last Modified:

Subreport in Details - shared variable-no value first record

CR 2008 V2. I have a report with a subreport in the details section to get one value via a shared variable. On the first record, the value is 0. How can I get a value for the first record?
0
Datakat
Asked:
Datakat
1 Solution
 
mlmccCommented:
The subreport must be in a section before you want to use the shared value.  Crystal uses a multipass method for rendering the reports.  
THe method is top down so the report header is done first then group headers then details then group footers

Subreports are the LAST objects evaluated in a section so the values from them are not known until after the subreport is evaluated which will then be after the section is displayed.

Try this
Insert a "second" details section
  Right click the detail section in the left margin
  CLick INSERT SECTION BELOW - Details B appears
You can click the left margin and drag the new section up so it is now Details A
Move the subreport to Details A
The value it evaluates will now be available in Details B which will have the rest of what you were displaying in the detail section

mlmcc
0
 
DatakatCrystal Report DesignerAuthor Commented:
Thank you.  I thought that might be the case, but wasn't sure if I was just missing something.
0

Featured Post

Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now