public byte[] Render(ReportFormatInfo formatInfo) { Microsoft.Reporting.WebForms.Warning[] warnings; string[] streamids; string mimeType; string encoding; string extension; byte[] result = this.m_Viewer.LocalReport.Render(formatInfo.FormatName, formatInfo.DeviceInfo, out mimeType, out encoding, out extension, out streamids, out warnings); return(result); }
public static byte[] RenderReport(string report, ReportFormatInfo formatInfo, ReportDataCallback_t cbGetReportDetails) { byte[] baReport = null; using (ReportViewer viewer = new ReportViewer()) { // viewer.ReportPath = System.Web.Hosting.HostingEnvironment.MapPath("~/" + report); viewer.LoadEmbeddedReportDefinition(report); System.Xml.XmlDocument rep = ReportRepository.GetReport(report); if (cbGetReportDetails != null) cbGetReportDetails(viewer, rep); rep = null; baReport = viewer.Render(formatInfo); } // End Using MyReportViewer return baReport; }
public static byte[] RenderReport(string report, ReportFormatInfo formatInfo, ReportDataCallback_t cbGetReportDetails) { byte[] baReport = null; using (ReportViewer viewer = new ReportViewer()) { // viewer.ReportPath = System.Web.Hosting.HostingEnvironment.MapPath("~/" + report); viewer.LoadEmbeddedReportDefinition(report); System.Xml.XmlDocument rep = ReportRepository.GetReport(report); if (cbGetReportDetails != null) { cbGetReportDetails(viewer, rep); } rep = null; baReport = viewer.Render(formatInfo); } // End Using MyReportViewer return(baReport); } // End Function RenderReport
public byte[] Render(ReportFormatInfo formatInfo) { Microsoft.Reporting.WebForms.Warning[] warnings; string[] streamids; string mimeType; string encoding; string extension; byte[] result = this.m_Viewer.LocalReport.Render(formatInfo.FormatName, formatInfo.DeviceInfo, out mimeType, out encoding, out extension, out streamids, out warnings); return result; }