紧急求救,在线等待--配置文件出错
配置错误
说明: 在处理向该请求提供服务所需的配置文件时出错。请检查下面的特定错误详细信息并适当地修改配置文件。
分析器错误信息: The located assembly's manifest definition with name 'Interop.Office' does not match the assembly reference.
源错误:
行 256: <add assembly="System.EnterpriseServices, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
行 257: <add assembly="System.Web.Mobile, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
行 258: <add assembly="*"/>
行 259: </assemblies>
行 260:
源文件: c:\windows\microsoft.net\framework\v1.1.4322\Config\machine.config 行: 258
程序集加载跟踪: 下列信息有助于确定程序集“Interop.Office”无法加载的原因。
=== Pre-bind state information ===
LOG: DisplayName = Interop.Office
(Partial)
LOG: Appbase = file:///c:/inetpub/wwwroot/chinaarton
LOG: Initial PrivatePath = bin
Calling assembly : (Unknown).
===
LOG: Policy not being applied to reference at this time (private, custom, partial, or location-based assembly bind).
LOG: Post-policy reference: Interop.Office
LOG: Attempting download of new URL file:///C:/WINDOWS/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET Files/chinaarton/19b3f19e/ec3b08fb/Interop.Office.DLL.
LOG: Attempting download of new URL file:///C:/WINDOWS/Microsoft.NET/Framework/v1.1.4322/Temporary ASP.NET Files/chinaarton/19b3f19e/ec3b08fb/Interop.Office/Interop.Office.DLL.
LOG: Attempting download of new URL file:///c:/inetpub/wwwroot/chinaarton/bin/Interop.Office.DLL.
WRN: Comparing the assembly name resulted in the mismatch: NAME
--------------------------------------------------------------------------------
版本信息: Microsoft .NET Framework 版本:1.1.4322.573; ASP.NET 版本:1.1.4322.573
问题点数:100、回复次数:13Top
1 楼Eddie05(♂) №.零零伍 (♂)回复于 2004-12-01 11:04:24 得分 0
up~Top
2 楼sduwjr(一名程序员)回复于 2004-12-01 11:43:20 得分 0
忘了说明,这是由于引用dll造成的。我的office安装在d盘,而部署机的office安装在c盘,office版本都一样。但是我在引用后,在复制到本地选项设置为true,难道还不行吗?Top
3 楼cancersyf(fengzhimei)回复于 2004-12-01 12:02:17 得分 30
你的bin目录下有Interop.Office.DLL吗,注意命名空间和输出文件名。Top
4 楼sduwjr(一名程序员)回复于 2004-12-01 13:45:23 得分 0
to:cancersyf(fengzhimei)
我的bin目录下有office.dll。引用代码using Office;在我本地调试没问题的。然后我整个copy到别的机器上就不行了,报第一贴的错误。部署机上的.net framework版本和office版本和我开发机上一样的。Top
5 楼zlc810821(卷心菜)回复于 2004-12-01 13:53:16 得分 20
应该是缺少Interop.OfficeTop
6 楼sduwjr(一名程序员)回复于 2004-12-01 14:40:42 得分 0
卷心菜能不能说得详细一些?Top
7 楼sduwjr(一名程序员)回复于 2004-12-01 16:01:43 得分 0
着急啊,真的在线等待。Top
8 楼sduwjr(一名程序员)回复于 2004-12-02 08:41:03 得分 0
这个问题一定要解决的Top
9 楼zhanqiangz(闲云野鹤-Overriding)回复于 2004-12-02 08:58:16 得分 30
意思是本地的'Interop.Office'组件和引用的组件不匹配,建议你重新引用这个 的'Interop.Office'd的dll.Top
10 楼sduwjr(一名程序员)回复于 2004-12-02 10:02:11 得分 0
怎么重新引用?部署机上除了.net framework,没有开发环境的。在我开发机上调试是没有问题的。大哥给个方法吧,分不够可以再加。拼了!Top
11 楼sduwjr(一名程序员)回复于 2004-12-02 10:07:10 得分 0
我用菜单添加引用,选择的是.net组件。复制到本地选择了true,bin下面也有Interop.Office.dll。以下是代码:
............
using Office;
namespace chinashoot
{
..................
private void button_refreshart_Click(object sender, System.EventArgs e)
{
Word.ApplicationClass word = new Word.ApplicationClass();
Type wordType = word.GetType();
Word.Documents docs = word.Documents;
......................
现象就是请求任何一个aspx页面都会出现第一贴的情况,估计是编译的时候报的错吧,可是我在本地生成的时候没有报错啊Top
12 楼qixiao(七小)(Gadgets中文网http://www.gadgets.net.cn)回复于 2004-12-02 10:20:15 得分 20
Dcomcnfg中为com组件添加足够的权限试试Top
13 楼sduwjr(一名程序员)回复于 2004-12-02 12:49:14 得分 0
今天奇迹般的好了,不知道是重新启动了机器还是重新编译的缘故,但是总归是出现过问题了,如果再出现相同的问题,还要翻出来问啊。问题自己解决了自己,但是分照给。Top




