.net 4.5 升级后 System.Web.Http 丢失 [英] System.Web.Http missing after .net 4.5 upgrade

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

问题描述

我刚刚使用 目标框架迁移器将我的解决方案升级到 .net 4.5,然后是包管理器控制台命令:

I've just upgraded my solution to .net 4.5 using Target Framework Migrator, and then the package manager console command:

Update-Package -Reinstall -IgnoreDependencies

在我使用的其中一个项目中:

In one of my projects I am using:

using System.Web.Http.Controllers;
using System.Web.Http.Filters;

代码使用HttpActionContextReflectedHttpActionDescriptor.我注意到 System.Web.Http 已从我的引用中删除,并且在添加新引用"窗口中不再可用.怎么回事?

The code uses HttpActionContext and ReflectedHttpActionDescriptor. I notice that System.Web.Http has been removed from my references, and is no longer available in the Add New Reference window. What's going on?

推荐答案

您是否查看了添加新引用"的扩展部分,而不是框架?

Have you looked in the Extensions part of the "Add new reference", instead of Framework ?

如果不存在,则在 NuGet 上的 Microsoft.AspNet.WebApi.Core 包中.

If it's not there, it's in the Microsoft.AspNet.WebApi.Core package on NuGet.

这篇关于.net 4.5 升级后 System.Web.Http 丢失的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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