开发者

ReSharper 5.0 choking on strong-typed view model that's located in same project

开发者 https://www.devze.com 2023-01-08 15:37 出处:网络
I\'m using VS2010, ASP.NET MVC 2, and ReSharper 5.0.When I create a new view that\'s typed off of a model from the same project as my view, ReSharper doesn\'t see the reference to the model.

I'm using VS2010, ASP.NET MVC 2, and ReSharper 5.0. When I create a new view that's typed off of a model from the same project as my view, ReSharper doesn't see the reference to the model.

This is the definition of my view:

<%@ Page Language="C#" Inherits="System.Web.Mvc.ViewPage<Web.Domain.UserViewModel>" %>

Domain.UserViewModel is red, and the ReShaper tooltip to add a reference pops up. This is really annoying because I cannot use intellisense for Model and ReSharper shows numerous errors in the view.

This is strictly a ReSharper code-inspection issue. The view actually functions 开发者_运维知识库properly if I run the code.

If I change Web.Domain.UserViewModel to an object from another project then the red dissapears and everything is fine. Does anyone know how I can make it recognize the models from the Web project correctly?


Did you try latest bug fix update, ReSharper 5.1?

0

精彩评论

暂无评论...
验证码 换一张
取 消