如何在Asp.net Core中使用肥皂网络服务? [英] How to use soap web services in Asp.net Core?

查看:72
本文介绍了如何在Asp.net Core中使用肥皂网络服务?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一些wsdl为肥皂网络服务生成的类.这些正在使用命名空间System.Web.Services.如何在asp.net核心中使用它们?

I have got some classes generated by wsdl for soap web services. These are using namespace System.Web.Services. How can I use them in asp.net core?

推荐答案

几天前我回答了以下问题.

I have answered few days back on following question.

ASP.NET 5添加WCF服务参考

在上述情况下,有一个WCF服务,在您的情况下是Web服务.

In above case there is a WCF service and in your case it is Web Service.

以下是您应该关注或考虑的事情.

Following thing you should concern or consider.

  1. 它不适用于CoreCLR
  2. 您必须按照以下方式添加对"System.Web.Services"的引用.

  1. It will not work with CoreCLR
  2. You have to add reference to "System.Web.Services" following way.

aspnet50":{ "frameworkAssemblies":{
"System.Web.Services":" }, 依赖关系":{ "ClassLibrary2":"1.0.0- *" } }

aspnet50": { "frameworkAssemblies": {
"System.Web.Services": "" }, "dependencies": { "ClassLibrary2": "1.0.0-*" } }

所有其他步骤与创建类库项目并添加该项目的引用或将WSDL生成的类直接添加到asp.net 5项目中相似.

All other steps are similar that you have to create classlibrary project and add reference of that project or directly add class generated from WSDL to your asp.net 5 project.

注意:为此答案,我使用了VS 2015 CTP 5.

Note : For this answer I have used VS 2015 CTP 5.

这篇关于如何在Asp.net Core中使用肥皂网络服务?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆