Resharper not recognizing namespaces in web.config (KendoUI)

In my web.config (inside of an area), I have added the kendo.mvc.ui namespace.  When editing views and trying to manipulate a kendo control, the kendo.mvc.ui namespace is not being recognized by resharper, and autocomplete controls go away.  When suspending use of ReSharper, everything works just fine.  It'd be nice to not have to suspend/resume ReSharper every time I want to edit a view (and in some cases the controllers using the kendo.mvc.ui namespace).

An example of this problem can be found by adding the below to a namespace in your web.config (not the main one, but in an MVC project the web.config located in the "views" folder:

<system.web.webPages.razor>
   <pages pageBaseType="System.Web.Mvc.WebViewPage">
      <namespaces>
           <add namespace="Kendo.Mvc.UI" />
      </namespaces>
</pages>
</system.web.webPages.razor>


In any view taking advantage of the namespace try adding "@using Kendo.Mvc.UI" to the view, and see that ReSharper won't find / recognize the namespace.


Anyone come across a solution to this issue?  Is there something I'm doing wrong?

Thanks for any help!

10 comments
Comment actions Permalink

Hello Sig,

What ReSharper version do you use? Please let me know.

0
Comment actions Permalink

Hey Alex, I'm using  the latest version of Resharper, 7.0.1 .

Thanks for any insight!
-Sig

0
Comment actions Permalink

Hi Sig,

I believe this issue is going to be fixed in ReSharper 7.1. We're planning
to open EAP for it soon, so you're welcome to try it out when possible and
let us know the results here.

Thanks!
________________________
Alex Berezoutsky,
Support Engineer
JetBrains, Inc.
http://www.jetbrains.com
"Develop with pleasure!"

Hey Alex, I'm using  the latest version of Resharper, 7.0.1 .

Thanks for any insight!
-Sig
---
Original message URL:
http://devnet.jetbrains.net/message/5468515#5468515



0
Comment actions Permalink

Hi Sig,

Meanwhile, I was trying to check if we have this particular resolve problem in our YouTrack and failed to find a logged issue there. Could you please create and send me a small sample solution, which will demonstrate this? I'd like to verify if this bug is fixed for ReSharper 7.1 or not just to make sure I'm not mistaken in this case.

Thanks a lot!

________________________
Alex Berezoutsky,
Support Engineer
JetBrains, Inc.
http://www.jetbrains.com
"Develop with pleasure!"

0
Comment actions Permalink

Hey Alex,
I am also having troubles with namespace and pageBaseType recognition in Areas/web.config.  I am running version 7.1.1.  Just wondering if there have been any updates with this issue?
Thanks!  Kell~

0
Comment actions Permalink

Hi Kelly,

As above - could you please create and attach here a small sample, which will demonstrate it? All initial cases of such a resolve should be working fing in 7.1.1.

Thank you!

0
Comment actions Permalink

Hey Alex,
Attached you will find a sample PortableAreas application.  Notice that Index.cshtml is unable to resolve the namespaces defined in Areas/web.config.
I am starting to wonder if this may be due to the structure i am using to support MvcContrib's PortableAreas?
Thanks!  Kell~



Attachment(s):
SampleAreasProject.zip
0
Comment actions Permalink

Hi Kelly,

It looks like my ReSharper instance is resolving it just fine, and prompts to add corresponding using. I've attached a screenshot.

Am I looking at a worng place?
Thanks.



Attachment(s):
screen423.png
0
Comment actions Permalink

Hey Alex,
I appologize for not being more clear about the issue.  The issue is that the "using prompt" should actually not show up because that namespace has already been included in the Areas/web.config

  <system.web.webPages.razor>
    <host factoryType="System.Web.Mvc.MvcWebRazorHostFactory, System.Web.Mvc, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
    <pages pageBaseType="System.Web.Mvc.WebViewPage">
      <namespaces>
        <add namespace="System.Web.Mvc" />
        <add namespace="System.Web.Mvc.Ajax" />
        <add namespace="System.Web.Mvc.Html" />
        <add namespace="System.Web.Routing" />
        <add namespace="System.Web.Routing" />
        <add namespace="SampleAreasProject.Helpers" />        
      </namespaces>
    </pages>
  </system.web.webPages.razor>


Thanks! Kell~

0
Comment actions Permalink

Hi Kelly,

Thanks for clarification. I've logged this issue in YouTrack here: http://youtrack.jetbrains.com/issue/RSRP-338502.

Thank you for the report!

0

Please sign in to leave a comment.