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

Shared Variables, Sub Reports, and CSV export problem

Status
Not open for further replies.

ktonine

Technical User
Dec 5, 2009
1
US
I'm using Crystal Reports ver. 10.0.0.533 and trying to export to a csv file.

The Main report has one subreport. The subreport information is not going into the csv export.

Elsewhere on the site I saw a proposed work-around using shared variables. I followed that advice and what I find is that the shared variable's value appears onscreen with the correct value as set in the subreport -- but the exported csv file retains the value of the variable BEFORE it entered the subreport.

I am declaring the shared variable in the report header section. The subreport is in GH1a and I have a formula there that also declares the shared variable. I am displaying the value of the shared variable in GH1b.

Any suggestions or other possible workarounds would be greatly appreciated - though be forewarned that I am a complete novice when it comes to Crystal Reports.


 
Several potential solutions to this problem. Save the value into a shared variable in the subreport, and then suppress all the sections in the subreport. In the main report, have a formula to retrieve the shared variable.

Also note, the subreport must be in a section above the one with the formula to retrieve the variable.

If that doesn't work, have a look at our Grid UFL. That lets you create a working grid and you can load and retrieve a value for each cell in the grid. Then save the grid with a comma, tab or any other delimiter you want. Works well with group level reports and subreports.

Editor and Publisher of Crystal Clear
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top