System.ServiceModel 参考 [英] System.ServiceModel References

查看:46
本文介绍了System.ServiceModel 参考的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用 系统服务模型

using System.ServiceModel; 
using System.ServiceModel.Channels;
using System.ServiceModel.PeerResolvers;

在C# winform桌面应用程序中,但是我在Visual Studio 2015中找不到将其添加到项目References中,我猜必须是Framework中的System.SeviceModel,不确定

in C# winform desktop application, but I can't find it in Visual Studio 2015 to add it to the project References, which must be System.SeviceModel in Framework I guess, not sure

任何建议都是有用的

推荐答案

通过右键单击您的项目,依次转到属性、应用程序和目标框架,将项目目标框架更新到 .NET 4.5.将目标框架更改为 .NET Framework 4.5.

Update your project target framework to .NET 4.5 by Right clicking your project, going to properties, then application, then target framework. Change the target framework to .NET Framework 4.5.

在我的 VS2015 实例中,当我转到 Add References->Assemblies 时,System.ServiceModel 就在那里,它看起来在 C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.5 文件夹.

In my VS2015 instance, when I go to Add References-> Assemblies, System.ServiceModel is there, and it looks to be in the C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.5 folder.

如果 System.ServiceModel 不在列表中,您可以尝试通过右键单击-> 管理 NuGet 包-> 浏览,然后搜索 ServiceModel,从 Microsoft 获取.

If System.ServiceModel is not in the list, you can attempt to get it via the Right Click-> Manage NuGet packages-> Browse, and search for ServiceModel, get the one from Microsoft.

这篇关于System.ServiceModel 参考的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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