简体   繁体   中英

Intellisense showing false errors, cannot “go to definition” (Visual Studio 2013)

I am finding that on my computer, Intellisense often fails (doesn't appear) and that I often get false errors (red underlines) in my code when my code actually compiles and works OK.

Typically, the error is on a using directive and when you hover it says "The type or namespace name 'X' could not be found". However namespace X is defined within the current project.

If I compile, the errors temporarily disappear until I change the code, then they come back a couple of seconds later.

I've tried cleaning and rebuilding the project, deleting my Visual Studio project and global settings, deleting the bin/obj folders etc. Everything works fine in VS 2012.

What could be making intellisense misbehave like this?

have you recently added some extensions to File Extension? if yes, then go to Tools> Options> Text Editor> File Extension, and then clear all extensions you didn't add, then close the solution and open it again

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM