Hi,
my product name is NetAdvantage Ultimate 2013 Vol. 1I have a similar problem than http://www.infragistics.com/community/forums/t/79908.aspx
By using HTML5 Report Viewer on azure website (MVC4), report exporting is not working,on my development environment it works fine but once deployed to Azure it doesn't (the report viewer work correctly but not the export buttons).
The error message is :An error occurred while exporting the report. Object reference not set to an instance of an object. In web.config I use the following parameters :
<system.webServer><validation validateIntegratedModeConfiguration="false" /><handlers><add name="IgReportingResourcesHandler" verb="*" path="*.igrResource" type="Infragistics.Reports.Server.ResourcesHandler, InfragisticsWPF4.Reports.Server.v13.1" /></handlers><modules><add name="ReportProcessorServiceModule" type="Infragistics.Reports.Server.ReportProcessorServiceModule, InfragisticsWPF4.Reports.Server.v13.1" /></modules></system.webServer>
and in global.asax.cs
routes.Ignore("{*allReportingResources}", new { allReportingResources = @".*\.igrResource(/.*)?" });
I use the following code on the viewpage :
<div id="report"></div>
<script type="text/javascript">$.ig.loader({scriptPath: "/scripts/Infragistic/scripts/",cssPath: "/scripts/Infragistic/css/",resources: "igReportViewer"});
$.ig.loader(function () {$("#report").igReportViewer({height: 600,locale: 'fr',pageFit: "fitToPage",renderSettings: {definitionUri: "avitax-total;component/Ventes.igr",
serviceEndpointUri: "/ReportService.svc/ajaxAddress/"}});});</script>
The dll deployed to azure website bin folder : Infragistics.Web.Mvc.Documents.Reports, Version=13.1.20131.2103,Infragistics45.WebUI.Documents.Reports.v13.1, Version=13.1.20131.2045,InfragisticsWPF4.Controls.Reports.v13.1InfragisticsWPF4.Models.Data.v13.1InfragisticsWPF4.Models.Presentation.v13.1InfragisticsWPF4.Reporting.v13.1, Version=13.1.20131.2073,InfragisticsWPF4.Reports.Client.v13.1InfragisticsWPF4.Reports.Controls.Charts.XamDataChart.v13.1InfragisticsWPF4.Reports.Controls.Common.v13.1InfragisticsWPF4.Reports.Controls.DataVisualization.v13.1InfragisticsWPF4.Reports.Excel.v13.1InfragisticsWPF4.Reports.Pdf.v13.1InfragisticsWPF4.Reports.Server.v13.1InfragisticsWPF4.Reports.v13.1InfragisticsWPF4.v13.1
May be some infragistics reference is missing on my deployment ?Thanks for your help, Regards
Hi jfpuche,
Thank you for posting in our forum.
I would suggest you to try adding the following assemblies to the project:
InfragisticsWPF4.Reports.Controls.Editors.XamColorPicker.v12.2.dll
InfragisticsWPF4.Reports.Controls.Editors.XamSlider.v12.2.dll
InfragisticsWPF4.Reports.Controls.Menus.XamDataTree.v12.2.dll
InfragisticsWPF4.Reports.Controls.Menus.XamMenu.v12.2.dll
Also, make sure you are ignoring correctly the route to the service:
routes.Ignore(“ReportService1.svc/{*pathinfo}”);
Let me know if this helps.
I've the same errors with the new assemblies and the route ignoring.
I've also tried to export by
var fichier = "ReportExport_" + DateTime.Now.ToShortDateString() + ".pdf";var reportUri = new Uri("avitax-total;component/Ventes.igr", UriKind.Relative);using (var exporter = ServerExporterFactory.CreateExporter(reportUri)){var memoryStream = new MemoryStream();var data = new DataSourceValue { Name = "Sales", Value = model.SalesList };
IEnumerable<DataSourceValue> dataList = new List<DataSourceValue>() { data };exporter.DataSources = dataList;exporter.Export(memoryStream, "PDF");SendStreamToResponse(memoryStream, fichier, "application/pdf");memoryStream.Close();}
And I have the following error message
[NullReferenceException: Object reference not set to an instance of an object.] Infragistics.Documents.Reports.TTF.Font.Subset(Boolean regular) +56 Infragistics.Documents.Reports.PDF.Font.EmbedData() +46 Infragistics.Documents.Reports.PDF.PdfDocument.Generate(Stream stream) +142 Infragistics.Documents.Reports.Report.Report.Publish(Stream stream, FileFormat format) +2580 Infragistics.Reports.Pdf.PdfDocument.Export(Stream targetStream) +138 Infragistics.Reports.Engine.ReportExporter.ExportInternal(IReportItemVisitor reportItemVisitor, IDocument document, Stream targetStream, ExportCallback callback, IReportItemRendererFactory factory, ICancelationProvider cancelationProvider) +201
Is it possible for you to provide a small running project demonstrating this error, so I can investigate it further?
Thank you.
please find as attachment the source of mvc application with export error when deployed on azure
Result :
http://devavitaxreport.azurewebsites.net/home/ReportExport
I would be willing to bet that we are looking for the same solution. My thread is here. Did you happen to notice if the icons on the Export buttons are not showing? You can see a screenshot example in that referenced thread.