摘要: 在我将一个.net framework 4.0+mvc4+ef5的项目,升级到.net framework 4.6.1+mvc5+ef6之后,解决了所有的升级带来的问题,唯独在razor的cshtml页面中,所有关于Expression<>的引用的方法全都报错,例如System.Web.Mvc.Html空间下的一系列@Html.DisplayFor()等等。razor页面可以正常编译及运行,但是页面编辑时报错,智能感知也不能正常使用。 具体的提示就是“The type 'Expression<>' is defined in an assembly that is not referenced.You must add a reference to assembly 'System.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.”。 阅读全文
posted @ 2018-05-30 21:53 览岳 阅读(1187) 评论(0) 推荐(0) 编辑