【问题标题】:Cannot Update WCF reference for android application无法更新 Android 应用程序的 WCF 参考
【发布时间】:2020-12-27 20:57:30
【问题描述】:

顾名思义,我无法更新对服务的引用。我在我的机器上启动服务,然后尝试更新服务,但无济于事。根据错误日志,我得出的结论是我缺少 Java.Interop... 但是我检查了,在我的任何一个解决方案中都没有看到对该文件的任何引用。我认为其他错误是从那里级联的。这是日志:

Resolving project references ...
Importing web service metadata ...
Number of service endpoints found: 2
Scaffolding service reference code ...
Warning:Warning: Cannot import wsdl:portType
Detail: An exception was thrown while running a WSDL import extension: System.ServiceModel.Description.DataContractSerializerMessageContractImporter
Error: Could not load file or assembly 'Java.Interop, Version=0.1.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065'. The system cannot find the file specified.
XPath to Error Source: //wsdl:definitions[@targetNamespace='http://tempuri.org/']/wsdl:portType[@name='IDeliveryService']
Warning:Warning: Cannot import wsdl:port
Detail: 
XPath to Error Source: //wsdl:definitions[@targetNamespace='http://tempuri.org/']/wsdl:service[@name='DeliveryService']/wsdl:port[@name='BasicHttpBinding_IDeliveryService']
Warning:Warning: Cannot import wsdl:binding
Detail: There was an error importing a wsdl:portType that the wsdl:binding is dependent on.
XPath to wsdl:portType: //wsdl:definitions[@targetNamespace='http://tempuri.org/']/wsdl:portType[@name='IDeliveryService']
XPath to Error Source: //wsdl:definitions[@targetNamespace='http://tempuri.org/']/wsdl:binding[@name='NetTcpBinding_IDeliveryService']
Warning:Warning: No endpoints compatible with .Net Core apps were found.
Warning:Warning: Cannot import wsdl:port
Detail: 
XPath to Error Source: //wsdl:definitions[@targetNamespace='http://tempuri.org/']/wsdl:service[@name='DeliveryService']/wsdl:port[@name='NetTcpBinding_IDeliveryService']
Warning:Warning: Cannot import wsdl:binding
Detail: There was an error importing a wsdl:portType that the wsdl:binding is dependent on.
XPath to wsdl:portType: //wsdl:definitions[@targetNamespace='http://tempuri.org/']/wsdl:portType[@name='IDeliveryService']
XPath to Error Source: //wsdl:definitions[@targetNamespace='http://tempuri.org/']/wsdl:binding[@name='BasicHttpBinding_IDeliveryService']
Error:Error: No code was generated.
If you were trying to generate a client, this could be because the metadata documents did not contain any valid contracts or services, or because all contracts/services were discovered to exist in --reference assemblies. Verify that you passed all the metadata documents to the tool.
Done.

我检查了参考,它调用我的计算机,在我专门为它打开的端口上,它调用了一个打开的服务。 我已经尝试将它作为一个包找到并安装它,但我没有找到它。知道它来自哪里以及如何恢复它吗?

【问题讨论】:

    标签: c# android asp.net wcf


    【解决方案1】:

    你可以在这个目录中找到它:

    C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\MonoAndroid\v1.0\Java.Interop.dll
    

    然后回到你的项目并添加到你的项目中。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-10-16
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多