CR2008:Failed to open the connection. Failed to open the connection.<Report
I've just upgraded from Crystal XI R2 to Crystal 2008. All my reports open happily in Crystal 2008. I have also deployed the Crystal 2008 runtime to a Windows 2003 SP2 R2 server running ASP.NET 1 and ASP.NET 2. Before the Crystal 2008 runtime was installed on top of the already present Crystal XI R2 Runtime I could view RPT files via the .NET report viewer (version XI). Now that Crystal 2008 runtime is installed I receive an error message when I try to view the reports, again, via the .NET report viewer (version 12), although no code has changed apart from all references changed from XI to 2008.
CrystalDecisions.CrystalReports.Engine.ReportDocument oReportDocument = new CrystalDecisions.CrystalReports.Engine.ReportDocument();
Tables oTables = oReportDocument.Database.Tables;
foreach (CrystalDecisions.CrystalReports.Engine.Table oTable in oTables)
TableLogOnInfo crTableLogOnInfo = oTable.LogOnInfo;
crTableLogOnInfo.ConnectionInfo.IntegratedSecurity = true;
crTableLogOnInfo.ConnectionInfo.DatabaseName = "DB" ;
crTableLogOnInfo.ConnectionInfo.ServerName = "server" ;
CrystalReportViewer1.ReportSource = oReportDocument;
Error message is: 'Failed to open the connection. Failed to open the connection'.
Any help would be great.