Intellisense problem: Type is not defined but build is successful.

Hi,

Some of the types in my project have squiggly underlines that indicate the types are not defined. The types are actually defined in the same namespace as the class where they are used. The project builds successfully despite the squiggly underlines. "Go to definiton" functionality of intellisense stops working for the class because of the error indicators. I have tried deleting the intellisense database file but to no avail. Does anyone have experience with similar problem? The problem is not critical, however, very annoying.

I am using MS Visual Studio 2005 Team Edition.

Thanks.

[606 byte] By [StephenLin] at [2007-12-24]
# 1
When you put the cursor over one of the types with the squiggly underlines, what does the message say exactly?
DeborahK at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 2
It says "Type 'LayerCollection' is not defined." while 'LayerCollection' is defined in the same namespace, in different file in the same VB project. Even compilation should be unsuccessful with undefined types, but the project builds successfully.
StephenLin at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic IDE...
# 3
I got rid of the problem. The problem seemed to originate from the vbproj file that was somehow corrupted. What I did was to exclude the problematic file where the type was not defined from the project, then I re-added the file. The squiggly line is gone.
StephenLin at 2007-8-31 > top of Msdn Tech,Visual Basic,Visual Basic IDE...