Skip to Content
0

Crystal Reports vs 2017

Feb 19 at 09:14 AM

279

avatar image
Former Member

hi, hope someone can help as really stuck on this. I have a website project that was originally created in dotnet 2 and uses crystal reports. The old server it sits on is windows 2008 r2. the appPool is targeting framework 2. Up until recently I was using visual studio 2010 to ammend the report files while using 2013 community to build, compile and release the website as a whole.

We have moved everything to windows server 2016 and im trying to get everything to compile in vs 2017. I've downloaded cr for vs service pack 21 and ive tried changing the references and updating all crystal inserts within the config to 13.0.3500.0 from 3.0.2000.0. I've also tried changing the apppool from 2 to 4 but i still get the below error when i step through the code at rep.load (load report).

An unhandled exception of type 'System.BadImageFormatException' occurred in Unknown Module. 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. This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded. occurred

Any help would be appreciated

Angela

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

4 Answers

Best Answer
Don Williams
Feb 21 at 03:22 PM
0

Hi Angela,

Did you change the web.config file also?

That error means it's missing the legacy mode in the config file but using 3500 assemblies it is no longer required.

Search your WEB server for an older web.config file and verify it's the only one.

Use ProcessMonitor to see where it's being loaded form.

AppPool must also be using 3.5 or above framework now also.

Don

Show 5 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Thanks Don i'll try the above and report back

0
Former Member

Hi Don, ok..I did change the web config to use .35 versions and removed then put back the legacy flag..I think the problem may be due to the fact that the new service pack 21 seems to requires building on dotnet 4 ie the appool set to 4 or above. I know you mention 3.5 above but 3.5 runs off the 2.0 core framework. remember this website was built on 2 originally and uses nettiers to utilize in its data layer. I'm wondering if I can use an earlier service pack with vs 2017 as i know everything worked fine with vs 2013. Do you know if this is possible or if i am going to end up in a worse state and would probably be better just going back to vs 2013 rather than 2017

angela.

0

Ah, on the WIKI there is another config file you can use to go back to previous versions but still use SP 21/22.

But yes SP 21/22 will work in any version of VS 2010 and above.

Don

0
Former Member

hi Don, before I saw your answer I went ahead and updated the data access layer to use 4.5 so i could use the 21/22 service pack. I can now view some reports via the website. others are complaining about incorrect log on parameters which maybe a data source issue which i will investigate however i can no longer see design mode I can only see lists of binary type info...any ideas ?

0
Former Member

Hi Don, ive got the design view back...I had forgotten to grab the exe and took the msi when i did the reinstall. only one prob left which is the log on problem

[LogOnException: Error in File LoginDetailsLetter_Oct2015_PID 14080_15328_{A752939C-247D-4350-8505-E8A3F94B253F}.rpt:

Unable to connect: incorrect log on parameters.
0
Don Williams
Feb 26 at 05:39 PM
0

Wiki has a Parameter test app that allows setting connection properties. See if that works for you.

Show 2 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Hi Don, I had a look at the parameter app. I think the problem is this now...The reports were originally using a local db and the connection was using the sqloledb provider. Now im trying to connect to an amazon hosted 2016 db. The ones that are working are connecting to a ds. So I need to work out what provider I can use to connect to this new db hosted on amazon. If you have any experience with this I would appreciate your input. :)

This is really strange..when I check the database location its fine, test connection fine, verify database -fine. Click logon to server...not sure what im doing wrong

0
Former Member

Digging deeper ive got - An exception of type 'CrystalDecisions.CrystalReports.Engine.LogOnException' occurred in CrystalDecisions.ReportAppServer.DataSetConversion.dll

0
Don Williams
Feb 28 at 05:51 PM
0

It looks like you need to update the Report to use the Amazon DB connection. The error is because it's still trying to use the dataset. Not clear if you are streaming the data from Amazon into a dataset or trying to connect to the DB directly?

Not sure what it uses, try ODBC. Amazon likely has a KBA on how to connect and what client it needs to use.

If it's a SQL Server then you need to update to the MS SQL Native 11 client, you can get the MSI from Microsoft.

As for configuring it, I don't know, I'm sure Amazon has an article on how to...

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Mar 01 at 03:20 PM
0

All sorted now. i came across this old article (http://aspalliance.com/articleViewer.aspx?aId=490&pId=-1) which is self explanitory (Troubleshooting Database Login Errors using Crystal Reports with .NET ) which is still relevant well at least for me. Somehow the report object was losing the creds but doing it this way ties it down. Thanks for helping me through the swamp Don it was very much appreciated. :)

Share
10 |10000 characters needed characters left characters exceeded