views:

733

answers:

3

I've just created my first Preview 5 error and it doesn't seem to place nice with Resharper. All the C# in the Views are coming up with errors, things like <%= Html.Password("currentPassword") %> has the "currentPassword" highlighted with the following error: Argument type "System.String" is not assignable parameter type "string".

IList errors = ViewData["errors"] as IList; has the IList highlighted as "Can not resole symbol 'string'"

Has anyone seen this?

+2  A: 

Did you try latest nightly build of ReSharper 4.1? In some cases the bug in 4.1 manifests itself with numerous ambiguity errors, and it has been fixed within the follow up build.

Ilya Ryzhenkov
I'm on nightly 933, for some reason I thought I was an an release, need to remember to try them first before I start moaning!
Chris Canal
Installing the latest nightly sorted it, but it reset Visual Studio to defaults and cleared all my Live/File Templates!
Chris Canal
Chris, this shouldn't happen, we will try to reproduce it. It would be nice if you can tell us what templates did you have (live/file/surround), for which languages, shared or not, etc. Thanks for the info and sorry for inconvenience.
Ilya Ryzhenkov
A: 

If anyone finds this blog, the fix suggested above worked for me - I downloaded the latest 4.1 build, and the ambiguous reference problem is gone.

A: 

Sometimes this can occur when you don't fully qualify your Inherits attribute of your @Page directive. Even if it is in your web.config be sure and fully qualify your Inherits directive for R#. (At least as of build 4.1.943).

This bug has been reported here: http://www.jetbrains.net/jira/browse/RSRP-96241

Will Shaver