views:

524

answers:

2

Using VS2008 and R# 5 I'm running into an odd situation, where on an aspx page I keep getting

Cannot resolve symbol 'symbolname'

But the code compiles and runs fine. While having a fix for this would be great, I'm just trying to figure out if I'm losing my mind.

The CodeFile directive and Inherits directives are fine. If I compile the app or just let devenv sit for a bit it'll go away, but as soon as I save the aspx [via ctrl+s] R# suddenly has trouble with the Inherits attribute and flips out on every method in the page (OnClick etc).

// Anonymized of course but otherwise intact
<%@ Page AutoEventWireup="true" CodeFile="TestPage.aspx.cs" Inherits="TestPage" Language="C#" MasterPageFile="~/MasterPage.master" Title="Test Page Title" %>

This is mostly just a grievance, because since the code compiles it doesn't stop me from doing what I need.

I would post a bug report to the JetBrains site but first I would like to know I'm not alone. It could be my machine. Maybe when I roll to VS2010 in a couple weeks this will go away?

A: 

Hi, thanks for the post. Is this strange behavior reproducible on a simple WebSite? Please try it and send me solution. Thanks in advance! You could contact me directly via email. I'll try to reproduce this.

-- Kirill Falk Senior Quality Assurance Engineer JetBrains, Inc http://www.jetbrains.com "Develop with pleasure!"

KFalk
Hi Kirill, as I stated before, I didn't necessarily know if it might just be my configuration, so before I submit a test case, I wanted to see if anyone else had noticed it and just didn't think to mention it. Let me give it a week and if it's still doing this with no resolution or if anyone else posts to this, then I'll gladly submit a bug report. ~ I just hate to cause unnecessary bug reporting for an issue on my system, ya know? ~ I'll see if creating a new project will let me reproduce this behavior, and we can coordinate from there.
drachenstern
Bug report submitted with basic sample that is not completely indicative of true failure but demonstrates the error. (I don't have the time to filter down to exactly what's failing where or to build a huge project but I can cause the error condition to appear briefly)
drachenstern
May also be related to this bug-post because we use a lot of our own controls and so they're registered in the web.config instead of each page http://youtrack.jetbrains.net/issue/RSRP-173600
drachenstern
Also this bug http://youtrack.jetbrains.net/issue/RSRP-175833
drachenstern
If those are related to your issue, my similar issue may be unrelated. The project of mine with that issue doesn't have any custom controls registered in web.config.
patridge
Ok, but you get the same behavior, so mine may not be related to those. I'm not entirely sure what my problem _is_, so trying to find things that look related. Since I can push the error to occur in a fresh website project with nothing added, I don't think mine is necessarily related to those. Depends on what happens under the hood in R#.
drachenstern
I found another side-issue that may be related to my issue, regardless of its relation to your issue. If an "Imports" statements only purpose is to provide scope for an extension method used in a code-behind class, it is deemed "not required by the code" and flagged for "safe" removal. I am guessing this is another side-effect of my those same extension methods not being resolved by R# but being fine with the compiler. What was the URL for the bug you filed for this?
patridge
A: 

So no final resolution yet. According to tech-support this is a known issue and is being researched. Final resolution undetermined at this time. If you're experiencing a similar issue, just hang tight. URL: http://youtrack.jetbrains.net/issue/RSRP-178681

drachenstern