It happens quite frequently, more times per day, that with Visual Studio 2010, during the debugging, when I used Immediate commands like:
? NamedVariable
I receive the following error:
'NamedVariable' is not declared. It may be inaccessible due to its protection level.
In this case also other debug features seems gone, but I can set breakpoints, step into, step over, etc.
The solution is stop debugging, clean and rebuild the project, and retry.
I am developing a VB.NET Windows Forms application, but it happened with VB.NET WPF projects too. I never had this behavior with VS 2008.
Is this a known bug or could it be a problem of my environment/installation? Do you have any idea how to solve this little, but annoying issue?