Topic: Set Datasource for subreport in CrystalReport2011 Posted: 12 Mar 2012 at 10:46pm
I am trying to upgrade an asp website that previously used Crystal Reports 8.5 to generate its reports to use Crystal Reports 2011 instead.
By creating an RDC package to install the necessary Crystal Report 2011 dlls and update the javascript code for creating the crystal report object to use Server.CreateObject("CrystalRuntime.Application.11"), I was able to create a Crystal Report 2011 report object and generate a report. However, if the report has subreports, the data for that subreport does not seem to be exported along with it, so even if the corresponding sql code for the subreport, written in an XML file, returns data, that data is not shown in the report. If a grouping is added to the subreport, an error would occur during report generation which indicates that:
"This group section cannot be printed because its condition field is nonexistent or invalid. Format the section to choose another condition field."
To set the datasource of the subreport, this code was used:
This worked when CR8.5 was used. Data was exported to the CR8.5 subreport but when CR2011 is used, data from the specified recordset does not seem to be shown in the report.
The Crystal Report 2011 version that I am using is CR Developer, Version 14.0.1.287 RTM, Product Type:Evaluation as checked in the About SAP Crystal Report window.
Has the SetPrivateData command parameters already changed to CR2011? Is there another command that I can use aside from this to set the crystal report datasource? Can you help me figure out the cause of data not being exported to its corresponding subreport?
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum