Reports won't display any data

Stimulsoft Reports.Flex discussion
Locked
Dom
Posts: 9
Joined: Tue Sep 14, 2010 11:11 am

Reports won't display any data

Post by Dom »

Hi,

I've created a report in designer. It previews fine and I have saved it as a .mrt file. The Data connection in the the report is to an xml file hosted on a web server, so it has an absolute url.

When I try to open the report in my Flex application it is blank. There is no data and no labels.

The code I am using to display the report is:

Code: Select all

private function reportLoaded(e:Event):void {
				var report:StiReport = new StiReport();
				var xs:String = e.target.data;
				report.loadDocumentFromString(xs);
				report.show(reportViewer);
				
				
			}
I am using the latest release version of Resports.Fx for Flex in a Flash Builder app with Flex 4 SDK. I can see that the report string has loaded in the debugger and correctly references the url of my data.

How do I make the report display?

Thanks
Dom


Vladimir
Posts: 1462
Joined: Fri Apr 13, 2007 4:05 am
Location: Earth

Reports won't display any data

Post by Vladimir »

Hello,

The report.loadDocumentFromString() method loads a rendered report file (.mdc document). For loading a report file (.mrt template), please use the report.loadReportFromString() method.

Thank you.
Dom
Posts: 9
Joined: Tue Sep 14, 2010 11:11 am

Reports won't display any data

Post by Dom »

That works! Thanks
Locked