9

some are working some are not working.

for example,

i did

using System.Web.Security;

MembershipUser myObject = Membership.GetUser();
        string UserID = myObject.ProviderUserKey.ToString();
        Response.Write(UserID);

the membershipuser is not highlighted in green. and System.Web. is not listing objects

but the code is working fine though. How do I make the intellisense work fine?

Preet Sangha
  • 64,563
  • 18
  • 145
  • 216
Vivek Chandraprakash
  • 1,165
  • 2
  • 21
  • 54

6 Answers6

13

Try resetting your Intellisense cache, Edit>Intellisense>Clear local cache.

Or try nuking it - delete your [SolutionName].sdf and .suo files

Edit:

VS 2010 equivalent is Project>Rescan Solution

Preet Sangha
  • 64,563
  • 18
  • 145
  • 216
Dlongnecker
  • 3,008
  • 3
  • 25
  • 40
4

I'm using VS2010 and Project > Rescan Solution seems to do the trick, although it seems to take longer than normal. I suppose it's because it is rebuilding the entire cache, rather than selectively updating parts of it.

If you're using VsVim or other non-default keybinds, alt+P+S still does the trick.

TankorSmash
  • 12,186
  • 6
  • 68
  • 106
2

If the cs file's build action is not set to compile, that will also cause the Intellisense to not work within that file.

K0D4
  • 2,373
  • 1
  • 27
  • 26
1

The solution that worked for me is to use the following at the command line (or Start->Run):

devenv /resetuserdata

Mike Wilson
  • 397
  • 1
  • 3
  • 11
0

I'm using VS2005, but, I found that, in order convince it to build intellisense for boost, I had to specify the explicit path to the boost includes - shades of 1988! A relative path did not work. Dunno how this is going to affect the team, might try the environment variable trick to see if that's a workaround this poor indexing implementation.

https://social.msdn.microsoft.com/forums/en-US/fa8277f9-ecf0-40a6-8e0e-118e4615d5bc/intellisense-and-nonstandard-directories

Jon
  • 1,675
  • 26
  • 57
-1

I think the VS 2010 equivalent is Project>Rescan Solution – tletnes Jan 21 '13 at 22:50

This is what worked for me.

hotplasma
  • 68
  • 4