166

I have been having issues with Intellisense in Microsoft Visual Studio 2012. I will be working in a project, editing code and whatnot (after a period of time, anywhere from 5 minutes to over an hour) and all of a sudden, no more code suggestions or intellisense. Both seem to stop working completely at the same time.

The only solution that I have tried is to reset all my settings, close out of Visual Studio completely and reopen the project again. Is there a better solution or an update that will fix this?

TimS
  • 5,922
  • 6
  • 35
  • 55
Josh Menzel
  • 2,300
  • 4
  • 22
  • 31
  • 3
    Please limit your tags to those that are actually necessary. "microsoft" is not, as no one else makes Visual Studio or has vb.net. "application-settings" would seem to be about saving/reading the settings for an application you're writing, not an IDE you're using. You might also want to edit your question and break it up into some readable paragraphs; the wall of text you posted is hard to read, and the easier you make your question to read the better your chances of getting help. :-) – Ken White Dec 21 '12 at 00:21
  • 3
    Sorry about that, it's just that I get so worked up when things that should be working just aren't for any reason. – Josh Menzel Dec 21 '12 at 00:29
  • Do you have any add-ons installed? – bobek Dec 21 '12 at 01:48
  • 1
    +1. I had the same problem several times in VS 2010. Restart of VS usually helps. There is no need to reset settings. It happens rarely, so never was a big deal for me. – Victor Zakharov Dec 21 '12 at 02:20
  • No add-ons are installed at this time. – Josh Menzel Dec 21 '12 at 03:38
  • I noticed this started happening to me after I removed ReSharper (I've never used VS without ReSharper before that). – Matej Aug 22 '13 at 11:45
  • It seems one of the causes is if VS didn't expect code where you put it. For example, if you type "Dim obj As New Object = ", you can still get intellisense after the = if you hit Ctrl+Space but it won't come up automatically anymore. – Tony L. Feb 26 '15 at 22:45
  • Just started using release of VS2015. Intellisense was working fine, then I came out of a debug session and it stopped. Even utilizing Tony L's answer did not work. I just closed and reopened VS, and it started working again. – Ricky Jul 28 '15 at 19:46
  • just now I've had this problem while debugging an exception, VS opened the same file twice, for example Form1.vb. I was trying to edit the wrong one opened later – Ivan Ferrer Villa May 12 '17 at 07:57
  • Having the same issue still in '17, in multiple different file types – Andrew Feb 14 '18 at 21:20
  • Restarting the Visual Studio fixed it for me. – Pரதீப் Mar 12 '20 at 10:24
  • Stupid cause but it had me searching for 10 minutes. The file was not included in the project due to an unexpected reboot – MichaelD Jan 09 '23 at 08:24

31 Answers31

333

I should note that I haven't had the issue since upgrading my RAM. I can't confirm if it's related but the problem was prevalent when I had 2-4GB RAM. No problems since going to 8 and 16GB.

If only one file/window appears to be affected, close and reopen that file. If that doesn't work, try below.

In Visual Studio:

  1. Click Tools->Options->Text Editor->All Languages->General
  2. Uncheck "Auto list members"
  3. Uncheck "Parameter information"
  4. Check "Auto list members" (yes, the one you just unchecked)
  5. Check "Parameter information" (again, the one you just unchecked)
  6. Click OK

If this doesn't work, here's a few more steps to try:

  1. Close all VS documents and reopen
  2. If still not working, close/reopen solution
  3. If still not working, restart VS.

For C++ projects:
MSDN has a few things to try: MSDN suggestions

The corrupt .ncb file seems most likely.

From MSDN:

  1. Close the solution.
  2. Delete the .ncb file.
  3. Reopen the solution. (This creates a new .ncb file.)

Notes:

  • Tested in VS 2013/2015

Logging possible causes:

  • Copy/pasting controls in a source page. I found that my designer.vb file didn't update from this, either.
  • Copy/pasting code from another page that caused an error because the code copied referred to a control that wasn't on the page I was pasting to.
  • C++ project has corrupt .ncb file

(Please add to comments if you notice behavior that causes this.)

Tony L.
  • 17,638
  • 8
  • 69
  • 66
  • 13
    Had to just restart VS – Jonathan Brown Mar 23 '15 at 21:13
  • It just changed my theme to light. That's literally all it did. haha – Dagrooms Jul 27 '15 at 16:43
  • @Dagrooms What action changed your theme and what version of VS are you using? – Tony L. Jul 27 '15 at 16:57
  • Resetting the options as described in this post, VS2012 – Dagrooms Jul 27 '15 at 17:00
  • My intellisense is "flickering" now. It has never actually worked in a large project. Every once in a while, function names will be highlighted for a second, and then blend back to the color of the rest of the surrounding code. – Dagrooms Jul 27 '15 at 17:01
  • @Dagrooms Was your theme dark before? The first screen you get when you go to tools->options has the theme dropdown. I wonder if the dropdown defaulted to light/blue instead of remembering what you had and it changed when you hit ok. I tried this in 2015 and wan't able to reproduce that behavior. – Tony L. Jul 27 '15 at 17:08
  • @Dagrooms Does intellisense work well is smaller projects for you? My guess is the flickering means that you intellisense is now turned back on but the large project may be creating a performance issue. – Tony L. Jul 27 '15 at 17:37
  • Let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/84409/discussion-between-dagrooms-and-tony-l). – Dagrooms Jul 27 '15 at 21:32
  • @Dagrooms There's a few more things that can happen with C++ projects. I'll bet your .ncb file is corrupt. Try these https://msdn.microsoft.com/en-us/library/ks1ka3t6%28v=vs.90%29.aspx?f=255&MSPPError=-2147217396. – Tony L. Jul 31 '15 at 16:00
  • 2
    For me, restarting VS did NOT have the effect that closing and opening that file had. Thanks a lot! – MKesper Apr 19 '16 at 06:37
  • 1
    The Tools-> bit works on VS2015 Ultimate Update 2 as well, without restart. If only I could give this answer+1^6, I was in 2 minds to move to Eclipse >;-) That said, someone at MS ought to be circumcised for the improductivity that this bug caused worldwide – smirkingman Aug 08 '16 at 19:21
  • 1
    Another silly cause for missing function argument Intellisense can be an inaccessible protection level. For example, a `protected` ctor instead of `public`. The `protected` ctor will appear in the function list outside of accessible scope, but the argument intellisense will be missing, which is somewhat inconsistent IMHO. – Special Sauce Dec 29 '16 at 05:32
  • "close/reopen solution" worked for me. "Uncheck/check Auto list members" did not work. – Pierre Mar 14 '17 at 13:33
  • I had to delete and re-add the affected file in addition to the instructions in this answer. – kkuilla Apr 13 '17 at 09:54
  • Just remove .suo file. – mja Apr 20 '17 at 10:35
  • 3
    What worked for me was the check/uncheck thing, closing all windows and restarting. – Marvin Effing Aug 10 '17 at 09:41
  • Check/Uncheck of General and C# did not work for me but reopening the file did work. Visual Studio Ultimate 2013 w/ Update 5. – Jay Dec 12 '17 at 06:37
  • 1
    This should be accepted answer. Works in vs 2017 as well. This is such an " old ms" fix: - something doesn't work - do this few absurd things - ohh it works again – Michal Ja Mar 10 '18 at 15:38
  • 1
    Uncheck/check AND close/reopen the solution worked for me. On their own they did not work, they both had to be done in my case. – BoldAsLove Aug 06 '18 at 19:48
  • 1
    Steps 1-6 worked for me in VS 2017. I think it's caused by disabling resharper or if your resharper license expires. It doesn't set the VS defaults back. See this answer for more details: https://stackoverflow.com/a/8420870/151325 – goku_da_master Aug 30 '18 at 16:31
  • @guko_da_master I didn't have resharper when it happened to me. – Tony L. Aug 30 '18 at 17:48
  • None of this helped, even tried a reinstall. This was a clean install on a new Windows 11 install too. – niico Apr 20 '23 at 17:11
40

What works for me is removing the dynamically-built .suo file (Solution User Options), in the .vs (hidden) directory located at he same path as the solution file.

I have this problem sometimes coming back, and it's on different project's/solutions, but never VS wide. New Projects always work fine.

Running VS2015 Professional Update -2-

John Jesus
  • 2,284
  • 16
  • 18
Mevius
  • 538
  • 4
  • 4
  • This solution worked for me! `Microsoft Visual Studio Professional 2015 Version 14.0.25431.01 Update 3`. Thank you very much. – AndreaT Oct 10 '17 at 09:44
  • do NOT follow this advice. all of my project's configurations are gone now (include directories, defines, etc.). VS2017 – hacksoi Aug 15 '18 at 19:12
15

I am having the same issue; Intellisense randomly will stop showing in some files, but not others. I just had it happen to me again. Hitting Ctrl + Space won't show anything in Form1, switching to Form2 or any other class will pop up the list as expected. Restarting Visual Studio usually does the trick, though it's highly annoying and ridiculous for such a basic feature to be broken...

SharpC
  • 6,974
  • 4
  • 45
  • 40
knrdk
  • 536
  • 5
  • 13
14

I found a solution that works for me 100% of the time (I do not have ReSharper installed). Pressing Refresh in Solution Explorer makes IntelliSense come back.

henrikmerlander
  • 1,554
  • 13
  • 20
11

I spent a lot of time researching the same problem. Some solutions related this bug with some referenced assemblies. Others said that Microsoft.Windows.Design.Extension.dll and .Interactivity.dll should be in the references of the project. But none of these solutions worked for me.

I think it is a bug in Visual Studio 2012, Microsoft has to fix it.

SharpC
  • 6,974
  • 4
  • 45
  • 40
Sanfoor
  • 311
  • 2
  • 5
  • 3
    I have visual studio 2013 and this is still happening. Is this still a bug? – Zein Sleiman Aug 06 '14 at 21:54
  • 1
    Yes, it is. And unfortunately over the last couple of years VS has been getting slower and buggier with each iteration it seems. – PaulK Jan 06 '15 at 22:01
  • 38
    This should not be the accepted answer. Tony L's answer below is correct. – Scott R. Frost Apr 17 '15 at 14:30
  • I have visual studio 2015 and intellisense is very slow or not working at all. Occasionally it works ok but usually not. – Nuts Sep 04 '15 at 06:33
  • 9
    Still getting this problem in VS2015 – Wouter Nov 12 '15 at 08:57
  • Sadly this has been happening even more frequently to me. VS2015 Update 3. – Kevin Finck Apr 14 '17 at 15:42
  • Still getting this problem in VS2017 – Jaider Jul 21 '18 at 01:35
  • 2
    It's still happening in VS 2019. Sucks to have to keep restarting to get a basic functionality to keep working. – Tundey Sep 30 '19 at 15:18
  • @Adrian: I think it's because this is a bug in VS. Everything else posted are suggestions that might temporarily resolve the bug...although I suspect it's the restarting of VS that's making those suggestions work. – Tundey Sep 30 '19 at 15:20
  • Thank you very much I have had a problem for a long time i added Microsoft.Windows.Design.Extensibility & Microsoft.Windows.Design.Interaction in vs2019 and worked – Mostafa Bagheri Apr 17 '22 at 11:18
11

What worked for me is by disabling and then re-enabling the Resharper

Goto
Tools -> Options-> Resharper ->General

Click
Suspend -> This disables the resharper

Then check your Intellisense is working or not. In my case, it did and then I resumed the Resharper.

If this does not work, you might need to Goto
Resharper -> Options-> Environment -> Intellisense -> General

And
Change Intellisense to Visual Studio

ANewGuyInTown
  • 5,957
  • 5
  • 33
  • 45
7

It didn't work for me with all those steps. Strangely enough I noticed Intellisense was working for another solution in visual studio 2015, but not for a specific one.

I located and deleted the .suo file and restarted visual studio. That fixed it for me.

Abhishek Tiwari
  • 417
  • 3
  • 14
2

I had the same problem on Visual Studio 2010 on C++ and I surpassed it by Tools -> Options -> Text Editor -> C/C++ -> Advanced -> Disable database -> False, Ok ; Close VS; open VS and voila.

GreatDane
  • 683
  • 1
  • 9
  • 31
  • Did you test it before restarting VS? I'm wondering if the restart alone fixed it. – Tony L. Nov 05 '15 at 15:02
  • 1
    At first, I tested it once before VS restart and it didn't work, changed that option several times then restarted and after restart it had other behavior according to the last change; ergo I deduced the effects take place after VS restart. – GreatDane Nov 05 '15 at 22:34
2

I was facing this problem in Visual Studio 2015 + C#.

After a while, I solved this way:

1) To go: Tools -> Options -> Text Editor -> C#

2) Check these options "Auto list members" and "Enable virtual space".

Probably, some extensions, like R#, disable these options for use their tools.

Fernando JS
  • 4,267
  • 3
  • 31
  • 29
2

With visual studio > 2015 I deleted the .suo file. (search for it in your project through file explorer)

Restart visual studio and you're good to go.

Mo D Genesis
  • 5,187
  • 1
  • 21
  • 32
1

I am facing the same issue with Visual Studio 2015 Preview. I have closed that respective file and re-opened it. That fixes it for me :).

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Rahul Techie
  • 363
  • 2
  • 8
1

In my case, I had added an .ascx.cs into the project via right-click => "Include in Project", but the project had it set as "Content" instead of "Compile". Once I set this to "Compile", intellisense began working again.

Keith
  • 5,311
  • 3
  • 34
  • 50
1

MS Visual Studio 2017 Pro, C++ projects

Too many good answers for this question. This worked for me:


IntelliSense works only when i load the project by double clicking the solution file.

I tried all the above answers with unfortunately no luck. Dll's, setting, dependencies...you name it. It sucks that you have to go through all that for an autocomplete....miss my Vim config....

Community
  • 1
  • 1
Franx
  • 87
  • 1
  • 10
0

Try to install the update 1 package, link. I have had the same problem and solved when I installed the update.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Cedar
  • 303
  • 1
  • 13
0

I have VS2012 update 4 and the problem is intermittent, but once it strikes on that particular page being edited it is there to stay. One solution is simply to close the page and re-edit it.

Here's some KBD shortcuts to try to reboot it, but don't know if they work.

Visual Studio keyboard shortcut to display intellisense

None of those solutions worked for me, BTW I'm using C#...

I think this is another IS bug.... it's had lots of issues in the past.

Community
  • 1
  • 1
JWP
  • 6,672
  • 3
  • 50
  • 74
0

@TonyL's answer didn't work for me, but I noticed Intellisense stopped working in the foo class after I changed the method signature in the bar class.

Closing and reopening the foo.cs file fixed it.

Danny Beckett
  • 20,529
  • 24
  • 107
  • 134
0

One of the thing that just helped me is

  1. Deleting every project file that is out there. My project has 10 folder, 30+ files.
  2. Recreating the project.

This takes about 5 mins - but saves a lot of time as intellisense actually started working.

One thing to note was that the memory usage (right top corner of VS 2013 ultimate) shows about 40% drop.

John Saunders
  • 160,644
  • 26
  • 247
  • 397
AdmiralThrawn
  • 374
  • 5
  • 15
  • 2
    Small projects will be fine with this. I'm looking at an intellisenseless project with over 100,000 files right now though. – Dagrooms Jul 27 '15 at 16:45
0

I had the same issue, it turned out to be that nuget packages were not automatically downloaded for a solution i downloaded from the repository freshly, thus intellisense was not available since none of the required packages to show the right suggestions were available.

Ahsan
  • 2,488
  • 2
  • 22
  • 44
0

im currently watching a MVA python tutorial on youtube and noticed my intellisence had also disappeared, soon after they expalined why,

something along the lines of this (excuse my lack of proper coding vocabulary i am new to programming but i have found the solution)

Answer: " Visual studio can not always guess what you are trying to input - therefore it does not always realise that it needs to give you a hint, for example if you are trying to use a string within a variable and need intellisense to give you options for that strings content, you must sometime tell visual studio that this variable actually is a string.

example:

name = ' ' # insert this line to tell visual studio that your variable is a string.
name = input('whats your name? \n') 
name = name.upper() #then when you type name.u.... it will give you intellisense
0

I had the issue in just one file. After creating the new class and working on it, it hadn't been added to the scope of my project. So when I closed and reopened my solution the following day, the file wasn't in the project scope.

Adding the existing item to the project scope fixed it for me.

0

In my case, I was simply unobservant at first and didn't see that one of the 30+ projects in my solution said "(load failed)" even though one of its files was still loaded in the editor, but had no intellisense. Reloading the project did the trick.

jhclark
  • 2,493
  • 1
  • 20
  • 14
0

Intellisense did not recognized an imported namespace in my case, although I could compile the project successfully. The solution was to uncheck imported namespace on project references tab, save the project, check it again and save the project again.

Matias Masso
  • 1,670
  • 3
  • 18
  • 28
0

I had this problem when some of the dependent assemblies are changed but locked by an other instance of visual studio (2015).

Jeroen van Langen
  • 21,446
  • 3
  • 42
  • 57
0

My solutions (I was using perforce) is to load the entire solution instead of the individual file.

Originally I had loaded a file by click on it in perforce

Solution Close VS (which closed the individual file) Reopened by starting the solution file instead of the individual file

Bruce G
  • 1
  • 3
0

If you are using Master Pages then create a blank master page use that master page in your content page. If this resolve the problem then it means your original master page have some problem. Port your original code step by step to new master page and test after each port if intellisense is working properly. This trick solved my intellisense problem.

Muhammad Yousaf Sulahria
  • 1,708
  • 1
  • 14
  • 16
0

For python, try clicking on the "Python X.X" button on the left side of the bottom status bar and changing it to different values.

This is the only thing that worked for me.

user31415
  • 446
  • 7
  • 16
0

If anyone is still having this issue, simply close the solution and then reopen it.

0

I've dealt with this for as long as Visual Studio existed. And yes, even in the current version it still fails (especially for large projects.)

I want to share small free tool that my friend and I wrote to address this exact same issue. You basically close your solution, drag its folder into the icon for this tool and it will reset all intermediary files for you. (Read the text manual inside if you want to know which ones. It's not just one file.)

I use it to clean up all my VS projects. So here you go:

enter image description here

c00000fd
  • 20,994
  • 29
  • 177
  • 400
0

Visual Studio 2019

The only thing that worked for me: Go to Tools -> Options -> Text editor -> C# -> Intellisense

And turn off

enter image description here

Turns out I was too eager to try everything that's new in VS :) It was broken in only one solutions though.

Emilia Tyl
  • 565
  • 1
  • 5
  • 17
  • That did not work for me, i had to delete the '.vs' folder (at solution level, probably hidden). Now it seems to work again for me. – jaufer.k Oct 23 '20 at 13:32
0

The build + intellisense in the Error List quit working on my web project only. The fix that finally worked for me was removing the .csproj.user file. When I opened the solution Visual Studio recreated the file and it was all working as expected.

Then I deleted the new file and put my old one back and it was still fixed, so ¯\(ツ)

Homer
  • 7,594
  • 14
  • 69
  • 109
0

If you are using cmake, close the Visual Studio then delete the whole build folder and finally open it and rebuild everything. That works for me

Reza
  • 3,473
  • 4
  • 35
  • 54