Could not load file or assembly 'Microsoft.ReportViewer.Common, Version=11.0.0.0 異常處理


在本機開發asp.net .rdlc報表后,部署到本地沒有問題。

當把網站發布后部署在IIS上,新電腦上(只安裝了.net framwork4.5),提示如下錯誤:

 

“Could not load file or assembly Microsoft.ReportViewer.WebForms, Version=11.0.0.0……

 或者


”Could not load file or assembly 'Microsoft.ReportViewer.Common, Version=11.0.0.0……

 

針對如上問題,需要安裝如下組件:

ReportViewer.msi 

在安裝ReportViewer.msi時可能提示安裝:

SQLSysClrTypes.msi

安裝如上兩組件后,再次運行站點,還可能報錯:


“ASP.NET ReportViewer Native compiler return value: ‘[BC2001] file’ error”

不用擔心,按一下步驟處理:

1、選擇此站點的-》應用程序池,右擊-》點擊"設置應用程序池默認設置",如下圖:

2、選擇 -》“進程模型”->"標識"-》“自定義賬戶”,設置為管理員用戶名及密碼,運行下,成功。

 

參考資料:

http://stackoverflow.com/questions/22253607/could-not-load-file-or-assembly-microsoft-reportviewer-common-version-11-0-0-0

http://randypaulo.wordpress.com/2011/07/28/asp-net-reportviewer-native-compiler-return-value-%E2%80%98bc2001-file-error/

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM