cancel
Showing results for 
Search instead for 
Did you mean: 

assembly issues when trying to publish site with Crystal Reports Viewer

0 Kudos

Getting the below error when trying to publish our site from VS 2022 after we have added the crystal report viewer.

Using SAP Crystal Reports 2016 SP09 Patch 500 32 bit, and VS 2022 for development.

"Could not load file or assembly 'CrystalDecisions.ReportAppServer.ClientDoc' or one of it dependencies. An attempt was made to load a program with an incorrect format. ClientDoc.dll is version 13.0.32.4286. see image attachment.

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

CR designer doesn't come with all of the .NET runtime.

Download the EXE to integrate into VS, MSI packages are for distribution only.

CR runtime is configured for your application, don't use AnyCPU, set for x86 or x64, which ever platform IIS is set for.

There's a blog on the WIKI page to help you upgrade your project.

And No you can't distribute only the assemblies used, MUST use the MSI packages.

Answers (2)

Answers (2)

The install of the CR for VS for VS 2022 and setting all Copy Local to false worked for us.

Thanks for your help!

0 Kudos

be sure to install the CR for VS for VS 2022:

https://wiki.scn.sap.com/wiki/display/BOBJ/Crystal+Reports%2C+Developer+for+Visual+Studio+Downloads

Set all Copy Local to false

0 Kudos

So what we are seeing is when we use the GAC_MSIL standard DLLs (Crystalreports.Engine.dll, Shared.dll and Web.dll -- all 32bit versions) and then publish and compile additional CR dlls get added, one is the ReportAppServer.ClientDoc.dll. We run Sigcheck on the Engine.dll, Shared.dll and Web.dll and they all come in as 32 bit objects, but for the ClientDoc.dll it comes in as a 64 bit. Which causes the Visual Studio Publish to fail as stated in my earlier message. We are assuming it is because it is getting picked out of the GAC_64 instead of the GAC_MSIL folder. Do you know what may be causing this on publish/compile and how we can make sure we are using the ClientDoc.dll from the GAC_MSIL instead?

Thanks!

0 Kudos

May I add, we publish to our local machine before we bring the code over to our servers.