1

我已经在安装了 Windows server 2008 r2、iis 7 和 .net framework 3.5.1 的虚拟机上部署了一个网站。

我一直收到以下错误。

=========================================

Server Error in '/' Application.

Configuration Error

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately. 

Parser Error Message: Could not load file or assembly 'Microsoft.Office.Interop.Excel, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies. The system cannot find the file specified.

Source Error: 


Line 46:                <add assembly="stdole, Version=7.0.3300.0, Culture=neutral , PublicKeyToken=B03F5F7F11D50A3A"/>
Line 47:                <!--<add assembly="Microsoft.Office.Interop.Excel, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71E9BCE111E9429C"/>-->
Line 48:                <add assembly="Microsoft.Office.Interop.Excel, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" /></assemblies>
Line 49:        </compilation>
Line 50:     

Source File: C:\TFareDemo\web.config    Line: 48 

Assembly Load Trace: The following information can be helpful to determine why the assembly 'Microsoft.Office.Interop.Excel, Version=11.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' could not be loaded.


WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

Version Information: Microsoft .NET Framework Version:2.0.50727.5466; ASP.NET Version:2.0.50727.5456

==================================================== ======= 该应用程序具有生成 Excel 报告的功能。我还没有安装 Office,所以我在启动网站时遇到了麻烦。

  1. 我已经尝试过很多事情,比如安装 .net framework 1.1 可再发行包。
  2. 我还安装了 Office Open XML,因为我在某处阅读它可能会解决问题。

请帮我解决一下这个。我的网站是使用 vs 2005 开发的,我没有在上面提到的虚拟机上安装 vs 2005。

4

1 回答 1

4

我还没有安装Office

您需要在执行 Excel 处理代码的机器上安装 MS Office(或至少是 Excel)。没有 Excel,它就不会神奇地工作。

于 2013-04-09T05:23:25.433 回答