Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Crystal reports error in asp.net vb where no crystal reports needed

I am getting following 7 errors in my asp.net(vb) website.They occurred after I added reference to Microsoft Office 12.0 Object Library as per this SO post in an attempt to read individual excel sheet cells. Now the whole website fails to build. The most surprising thing about this is that why I am getting an error related to crystal report when I do not need it in my project?

Here are the 7 errors:

Error   Unknown server tag 'CR:CrystalReportViewer'.    C:\Users\ssaa\Documents\Visual Studio 2010\WebSites\Dpp2012\aspnet_client\system_web\4_0_30319\crystalreportviewers13\preview.aspx  130 

Error   Could not load file or assembly 'CrystalDecisions.Web, Version=12.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304' or one of its dependencies. The system cannot find the file specified.    C:\Users\ssaa\Documents\Visual Studio 2010\WebSites\Dpp2012\aspnet_client\system_web\4_0_30319\crystalreportviewers13\preview.aspx  3   

Error   Could not load file or assembly 'CrystalDecisions.ReportSource, Version=12.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304' or one of its dependencies. The system cannot find the file specified.   C:\Users\ssaa\Documents\Visual Studio 2010\WebSites\Dpp2012\aspnet_client\system_web\4_0_30319\crystalreportviewers13\preview.aspx  6   

Error   Could not load file or assembly 'CrystalDecisions.ReportAppServer.XmlSerialize, Version=12.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304' or one of its dependencies. The system cannot find the file specified.   C:\Users\ssaa\Documents\Visual Studio 2010\WebSites\Dpp2012\aspnet_client\system_web\4_0_30319\crystalreportviewers13\preview.aspx  7   

Error   Could not load file or assembly 'CrystalDecisions.ReportAppServer.ObjectFactory, Version=12.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304' or one of its dependencies. The system cannot find the file specified.  C:\Users\ssaa\Documents\Visual Studio 2010\WebSites\Dpp2012\aspnet_client\system_web\4_0_30319\crystalreportviewers13\preview.aspx  8   

Error   Could not load file or assembly 'CrystalDecisions.ReportAppServer.Controllers, Version=12.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304' or one of its dependencies. The system cannot find the file specified.    C:\Users\ssaa\Documents\Visual Studio 2010\WebSites\Dpp2012\aspnet_client\system_web\4_0_30319\crystalreportviewers13\preview.aspx  4   

Error   Could not load file or assembly 'CrystalDecisions.CrystalReports.Engine, Version=12.0.2000.0, Culture=neutral, PublicKeyToken=692fbea5521e1304' or one of its dependencies. The system cannot find the file specified.  C:\Users\ssaa\Documents\Visual Studio 2010\WebSites\Dpp2012\aspnet_client\system_web\4_0_30319\crystalreportviewers13\preview.aspx  5   

Any help would be highly welcome!

like image 832
rahulserver Avatar asked Jul 07 '12 09:07

rahulserver


2 Answers

Go to this location

[Windows Partition]:\Windows\Microsoft.NET\Framework\v4.0.30319\ASP.NETClientFiles\crystalreportviewers13\

open the preview.aspx file , and change 12.0.2000.0 to 13.0.2000.0

It works ;-)

like image 94
Ali Foroughi Avatar answered Sep 27 '22 22:09

Ali Foroughi


As well as fixing preview.aspx in the [Windows Partition]:\Windows\Microsoft.NET\Framework\v4.0.30319\ASP.NETClientFiles\crystalreportviewers13\ folder, you should also look for a folder called aspnet_client within your website root and apply the same change there.

If you use multiple websites within your IIS rather than just "Default Web Site" it will copy the crystalreportviewers13 folder into each one, so check them all.

like image 25
Alan Singfield Avatar answered Sep 27 '22 23:09

Alan Singfield