hello guys,
I have a dynamic report what uses a script datasource.
the script returns a RSTableModel (of course) as per the code below:
//this is a part of the code in the MemberhipAndPolicyDataExportForCarriersReport class
public RSTableModel generateReport(){
initializeReport();
createColumnHeaders();
generateMainContent();
generateDataTypes();
generateGrandTotal();
def td = new TableDefinition( headers.toList(), dataTypes.toList() );
def table = new RSTableModel(td);
for(line in this.data) {
table.addDataRow(line)
}
return table
}
// this is the script
MemberhipAndPolicyDataExportForCarriersReport report = new MemberhipAndPolicyDataExportForCarriersReport(memberships, productTypes, parameterMap['group'], parameterMap['asdate'], grandTotalPremium);
report.generateReport()
I can execute the report and export to excel with no errors, however when I try to preview the report, it gives me the following error:
http://postimg.org/image/u5qr8bthx/
if I click on configure list and then click back on preview, I get this:
http://postimg.org/image/k9po8onpx/
note: the results show up in the preview but still get an error.
this error happens only for this report. I have other reports using dynamic list(database datasource though) that preview mode works just fine. So I guess I’m doing something wrong ?
any ideas?
thanks in advance