I am making plain text for PDF in C # using Telerik:
using Telerik.Reporting;
using Telerik.Reporting.Processing
...
ReportProcessor reportProcessor = new ReportProcessor();
InstanceReportSource instanceReportSource = new InstanceReportSource();
instanceReportSource.ReportDocument = new MyReport();
RenderingResult result = reportProcessor.RenderReport("PDF", instanceReportSource, null);
This works fine locally.
I installed the Azure application service and I get the following error when running reportProcessor.RenderReport ():
An error has occurred while rendering the report: System.ArgumentException: Parameter is not valid.
at System.Drawing.Graphics.GetHdc()
at Telerik.Reporting.Pdf.PdfContext..ctor()
at Telerik.Reporting.Pdf.PdfDocument..ctor()
at Telerik.Reporting.ImageRendering.DocumentPdf.FindOrCreateDocument()
at Telerik.Reporting.ImageRendering.DocumentPdf..ctor(PdfRenderingContext context, IMeasureContext measureContext)
at Telerik.Reporting.ImageRendering.PdfReport.CreateDocument(IDictionary renderingInfo, IDictionary deviceInfo, CreateStream createStreamCallback, PageSettings pageSettings)
at Telerik.Reporting.BaseRendering.DocumentRenderingExtensionBase.CreateWriter(IDictionary renderingContext, IDictionary deviceInfo, CreateStream createStreamCallback, PageSettings pageSettings)
at Telerik.Reporting.ImageRendering.PdfReport.CreateWriter(IDictionary renderingContext, IDictionary deviceInfo, CreateStream createStreamCallback, PageSettings pageSettings)
at Telerik.Reporting.BaseRendering.RenderingExtensionBase.Render(Report report, Hashtable renderingContext, Hashtable deviceInfo, CreateStream createStreamCallback, EvaluateHeaderFooterExpressions evalHeaderFooterCallback)
I feel this may be a problem with the way I configured my Azure application service. Here is my configuration: - Location: Western USA (we are located in Utah) - the pricing level is "F1 Free" (also the western part of the USA) with 1 GB of storage and used by 2 applications.
Is my Azure application configuration missing something?
source
share