1

I have a Web service which, when updated on one computer with VS2008 works perfectly fine, but on another computer does not. The critical difference is the contents of the auto-generated Reference.cs.

In the correctly functioning environment, the methods have fully qualified class names, refering to classes in a class library. However, in the problem environment, the class names are unqualified and partial classes are declared near the end of the file. E.g.

public string MyMethod(MyClass pr_Class)
...
public partial class MyClass {
}

versus

public string MyMethod(Class.Library.Namespace.MyClass pr_Class)

This causes errors such as:

'<ClassType>' is an ambiguous reference between <ClassLibraryNamespace>.ClassType and <WebReferenceNamespace>.ClassType

The code is under source control. Checking out to the working environment works straight away, checking out to the problem environment will only work if the reference.cs is manually edited to be like the working environments. Transferring the project manually from problem environment to the working one only requires an "Update Web Reference" to be performed to allow compilation. Both Reference.cs files claim to be auto-generated by the same tool version. The settings from the good environment have been exported to the other. No success so far...

Any ideas would be greatly appreciated!

Matt

4

1 回答 1

1

好的,所以我有答案了。工作环境有一个长期被遗忘的用于导入 Web 引用的扩展库。自定义生成的 Web 服务代理解释了该过程。我是该项目的新手,所以对此一无所知!

于 2010-01-13T11:35:26.510 回答