0

I have created a desktop application in visual studio and sqlserver and when I created a setup, it is working on the development machine but when the setup is installed in the client machine together with crystal reports runtime engine, the application is not starting. I have implemented event logging and managed to get the following error for crystal reports.

Application: Crystals.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.BadImageFormatException
   at CrystalDecisions.Shared.SharedUtils..cctor()

Exception Info: System.TypeInitializationException
   at CrystalDecisions.Shared.SharedUtils.get_CurrentControl()
   at CrystalDecisions.Shared.SharedUtils.GetEffectiveCulture()
   at CrystalDecisions.Shared.LocaleManager..ctor()
   at CrystalDecisions.Windows.Forms.CrystalReportViewer.InitReportViewer()
   at CrystalDecisions.Windows.Forms.CrystalReportViewer..ctor()
   at Crystals.Form1.InitializeComponent()
   at Crystals.Form1..ctor()

Exception Info: System.InvalidOperationException
   at Crystals.My.MyProject+MyForms.Create__Instance__[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]](System.__Canon)
   at Crystals.My.MyProject+MyForms.get_Form1()
   at Crystals.My.MyApplication.OnCreateMainForm()
   at Microsoft.VisualBasic.ApplicationServices

I have also tried Microsoft Report Viewer RDLC and it is returning the following error


Faulting Application name:ReportViewerSample.exe,version:1.0.0.0, time stamp:0x6130af2a
Faulting module name:KERNELBASE.dll,version:10.0.10240.16384, time stamp:0x559f3b2a
Exception code:0xe0434352
Fault offset:0x000b3e28
Faulting process id:0x17b4
Faulting application start time:0x01d7a059329df75d
Faulting application path: C:\Program Files(x86)\Beymo\RDLCViewer\ReportViewerSample.exe
Faulting module path: C:\Windows\SYSTEM32\KERNELBASE.dll
Report id: 57ed1ef9-6ed3-418f-952a-aea23f09618b
Faulting package full name:
Faulting package-relative application ID:

Log Name:   Application
Source:     Application error
Event ID:   100

When I create a project without a report, it is working fine in both development environment and client machine. How can I resolve the issue?

Seru
  • 29
  • 7
  • The issue is the client machines are missing the runtime environment for either of those reporting tools. You haven't explained how you're building or what tools you're using to generate your deployment, but the commonly have a prerequisite section where you can include for external dependencies such as these. Otherwise you could always install them manually – Hursey Sep 02 '21 at 20:59
  • I have tried to build setup using visual studio, and also advanced installer and install shield limited edition. I've included the runtime engine in the setup as a pre requisite and install it in the client machine but I still get the same error. I am using crystal report sp30. – Seru Sep 03 '21 at 03:43

0 Answers0