Skip to Content
0
Former Member
Apr 23, 2013 at 12:44 PM

VS2008, C# Program: "x = new ReportDocument();" Throws exception

70 Views

Hello,

I have a C# program that I developed several years ago on a 32 bit work station running XP. I have since moved the a WIN7 64 bit work station. I haven't had to touch this app for a long time. I have been asked to make some changes to the app so I tried to run it on my work station, in debug mode, before making any changes and it throws the exception shown below. Can someone tell me how to begin to diagnose this issue? Thanks, John

System.TypeInitializationException was unhandled

Message="The type initializer for 'CrystalDecisions.CrystalReports.Engine.ReportDocument' threw an exception."

Source="CrystalDecisions.CrystalReports.Engine"

TypeName="CrystalDecisions.CrystalReports.Engine.ReportDocument"

StackTrace:

at CrystalDecisions.CrystalReports.Engine.ReportDocument..ctor()

at CrystalReportsDataSources.HbgCrystalReports..ctor(DbConnection dbc) in C:\_Source CS\CrystalReportsDataSources\CrystalReportsDataSources.cs:line 61

at TestPrintCrystalReport.TestPrintCrystalReport.Main(String[] args) in C:\_Source CS\TestCrystalReports\TestCrystalReports.cs:line 37

at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)

at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()

at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)

at System.Threading.ThreadHelper.ThreadStart()

InnerException: CrystalDecisions.CrystalReports.Engine.LoadSaveReportException

Message="An error has occurred while attempting to load the Crystal Reports runtime. Either the Crystal Reports registry key permissions are insufficient, or the Crystal Reports runtime is not installed correctly. Please install the appropriate Crystal Reports redistributable (CRRedist*.msi) containing the correct version of the Crystal Reports runtime (x86, x64, or Itanium) required. Please go to http://www.businessobjects.com/support for more information."

Source="CrystalDecisions.CrystalReports.Engine"

StackTrace:

at CrystalDecisions.CrystalReports.Engine.ReportDocument.CheckForCrystalReportsRuntime()

at CrystalDecisions.CrystalReports.Engine.ReportDocument..cctor()

InnerException: