.NET Tips and Tricks

Blog archive

Skipping Through Definitions and References in Visual Studio

In Visual Studio, if you want to find out what that xCt_1 variable really is or see the definition for that TranX class, the easiest way is to click on the variable or class name and press F12. You'll be taken straight to the statement that declares that variable or defines that class.

Once you get to the definition, if you want to see where that variable or object is used, press Shift_F12 and you'll open a window showing all the statements that use your selected name. Clicking on any one of those lines in the window will take you to the statement in the editor.

In the latest version of Visual Studio 2017, getting to a name's definition is even easier: hover your mouse over the variable or class name, press and hold the Control key, and then click on the name. You're taken straight to the definition.

Posted by Peter Vogel on 10/29/2018 at 11:46 AM


Featured

  • Bright Tunnel

    Visual Studio 16.4 Preview 2 Boosted by Extension Tech

    Microsoft today shipped Visual Studio 2019 v16.4 Preview 2, boosted with new features that come from formerly separate extensions.

  • Nebula

    .NET Core 3.1 Preview 1 Focuses on Blazor, Desktop

    The first preview of .NET Core 3.1 focuses on two of the big features highlighting the Sept. 23 release of .NET Core 3.0: Blazor (for C# Web development instead of JavaScript) and desktop development (Windows Forms and Windows Presentation Foundation).

  • Stone Steps Graphic

    Microsoft Research's SandDance Data Visualization Tool Goes Open Source

    A data visualization tool some four years in the making from Microsoft Research has been open sourced, available for use as an extension for Visual Studio Code or Azure Data Studio.

.NET Insight

Sign up for our newsletter.

Terms and Privacy Policy consent

I agree to this site's Privacy Policy.

Upcoming Events