or
//Code that calls the report designer goes here
ReportProcessor processor = new ReportProcessor(); RenderingResult result = processor.RenderReport("PDF", report, null); string fileName = "Report" + string.Format("{0:yyyy-MM-dd_hh-mm-ss-tt}", DateTime.Now) + ".pdf"; Response.ContentType = "application/pdf"; Response.AddHeader("Content-Disposition", "attachment; filename=" + fileName); Response.ClearContent(); Response.OutputStream.Write(result.DocumentBytes, 0, result.DocumentBytes.Length); Response.End();byte[] documentBytes = new List<byte>().ToArray(); for(int i=0; i<count; i++) { //Code that calls the report designer goes here ReportProcessor processor = new ReportProcessor(); RenderingResult result = processor.RenderReport("PDF", report, null); documentBytes = documentBytes.Concat(result.DocumentBytes).ToArray(); } string fileName = "Report" + string.Format("{0:yyyy-MM-dd_hh-mm-ss-tt}", DateTime.Now) + ".pdf"; Response.ContentType = "application/pdf"; Response.AddHeader("Content-Disposition", "attachment; filename=" + fileName); Response.ClearContent(); Response.OutputStream.Write(documentBytes, 0, documentBytes.Length); Response.End(); Hi all!
I'm trying to view the datasouce source of theTelerik Cross Tab example ie. productSalesDataSet but when i try to configure... so as to view after "Edit in DataSet designer..."
i get the error below.
Failed to open a connection to the database.
"This server version is not supported. You must have Microsoft SQl Server 2005 Beta 2 or later"
Change connection and try again.
I have SQL server 2008.
Can someone send the the query used in the productSalesDataSet so i can have a look. I think after i've seen it i'llget my crosstab to work
thnx so much.
| private void Chart_NeedDataSource(object sender, System.EventArgs e) |
| { |
| string strCompanyID = this.ReportParameters["CompanyID"].Value.ToString(); |
| // The above always gives the default parameter value in the sub report, but correct in the master report |
| // ... |
| } |
| Sunscape.TKS.Reports.KeyFigures report = new Sunscape.TKS.Reports.KeyFigures(); |
| report.ReportParameters["CompanyID"].Value = Session["intCompany_ID"]; |
| Telerik.Reporting.SubReport subReport = report.Items.Find("chartSubReport", true)[0] as Telerik.Reporting.SubReport; |
| subReport.Parameters[0].Value = Session["intCompany_ID"]; |
| this.ReportViewer.Report = report; |