How to get Visual Studio 2010 to highlight instances of a variable

后端 未结 10 1878
梦谈多话
梦谈多话 2021-02-03 21:28

I\'m new using vs2010 I\'ve read that when you click on a variable its suppose to highlight all the instances of that variable in that file and highlight red or show an error as

相关标签:
10条回答
  • 2021-02-03 22:08

    In case someone else bumps into this, much like I did looking for the same thing, Visual Studio Express editions don't support extensions, which means no selection highlighting in C++. More importantly, if you get an error trying to install an extension, don't worry, or rather, worry for other reasons, it's normal.

    nuGet in 2012 is the only exception I've bumped into, but personally I (and I know many like me) have to use 2010.

    0 讨论(0)
  • Options -> Environment -> Fonts and Colors -> Highlighted Reference then change foreground and background colors of your choice.

    0 讨论(0)
  • 2021-02-03 22:14

    The Highlight all occurrences of selected word extension in Visual Studio Gallery does just that.

    Highlight all occurrences of selected word

    0 讨论(0)
  • 2021-02-03 22:17

    On the Tools menu, click Options.

    In the Options dialog box, expand Text Editor , and then complete one of the following tasks:

    • For Visual Basic, expand Basic, click VB Specific, and then select or clear Enable highlighting of references and keywords.
    • For C#, expand C#, click Advanced, and then select or clear Highlight references to symbol under cursor.

    From: msdn

    0 讨论(0)
提交回复
热议问题