on 09-12-2014 11:51 AM
Hi,
I’m using Visual Studio with Crystal Reports 9 to create a Windows Form. I’ve changed the “Target Framework” of my project from 3.5 to 4.0. After that, I’ve started to receive an exception when I try to run my report. The exception says:
“Could not load file or assembly 'file:///C:\Program Files (x86)\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Common\SAP BusinessObjects Enterprise XI 4.0\win32_x86\dotnet1\crdb_adoplus.dll' or one of its dependencies. The system cannot find the file specified.”
The strange thing is that this does not happen ALL the time. It usually gives that exception, but ones in a while the report runs fine. What is causing that?
Thanks so much.
Aron
Hi Aron,
by Crystal reports 9 do you mean 9.0 file version?
If yes, then you should upgrade Crystal version because CR 9 does not support .NET framewor 4.0 or 3.5 or 3.1 or even 2.0.
See the compatibility chart.
http://wiki.scn.sap.com/wiki/pages/viewpage.action?original_fqdn=wiki.sdn.sap.com&pageId=56787567
With VS 2010 / 2012/ 2013 use SAP Crystal reports for Visual Studio SP10.
- Bhushan
Senior Engineer
SAP Active Global Support
Follow us on Twitter
Got Enhancement ideas? Try the SAP Idea Place
Getting started and moving ahead with Crystal Reports .NET applications.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
In your app.config file add this line:
<startup useLegacyV2RuntimeActivationPolicy="true">
PS - if you searched on the error you would have found multiple posts on how to fix that error.
Don
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
After you make sure you have the right version of the SDK as Bhushan outlined, one of the things that you need to be sure to do with the .NET 4.x framework is to go to the properties for each of the CrystalDecisions references and set "Embed Interop Types" to false. By default this is set to True.
-Dell
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.