Skip to Content
0
May 11 at 02:28 PM

ASP.NET with Crystal Reports doesn't work on Windows Server 2012 R2.

142 Views Last edit May 11 at 04:29 PM 3 rev

Hello,

I uptaded my project to CR 2020 and .net framework to 4.7.2.

Works fine in my local machine.

When I deployed on my Server(Windows Server 2012 R2 Standard, x64) I got the Exception:

CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)
at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)
at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToStream(ExportOptions options)
at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToStream(ExportFormatType formatType)
at Ticket.WattsBenefit.Web.BasePage.Processa_OnLine(RelatorioLogInfo Log) in C:\Projects\Watts\Reports\BR\WattsBenefit\Ticket.WattsBenefit.Web\Base\BasePage.cs:line 1675System.Runtime.InteropServices.COMException (0x800002CD): Erro no arquivo a9f76c4c-de60-4c24-aace-190dc0472b42_REL161 13528_10800_{75BD9C49-974F-4C9C-B3FD-77842D56413B}.rpt: falha ao carregar informações do banco de dados.
at CrystalDecisions.ReportAppServer.Controllers.ReportSourceClass.Export(ExportOptions pExportOptions, RequestContext pRequestContext)
at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)

In the line 1675 from file, I have this:

stream = Log.TipoArquivo.Codigo == 1 ? report.ExportToStream(ExportFormatType.PortableDocFormat) : report.ExportToStream(ExportFormatType.Excel);

What It's missing? Could help me?