Find Code using Go To All in Visual Studio 2022
In this Visual Studio 2022 tip, you’ll learn about the Go To All feature in Visual Studio and how you can use this command to better perform a focused search of your .NET code quickly.
The Go To All command lets you to go to a specific type, type, file etc. all from a single window inside your Visual Studio.
How to Open Go To All Window in Visual Studio 2022?
There are couple of ways in which you can open the “Go To All” windows in Visual Studio.
- You can use the shortcut key “Ctrl +T“
- You can navigate to the Edit Menu -> Go To -> Go To All in your Visual Studio 2022 Editor.
This will display a small window just on the top right corner of your Visual Studio Code Editor.
You can start typing in the search textbox of the GoTo All window where the results will start appearing in a drop down list. If you want to quickly navigate to the element, you’ll simply need to select it from the list that is displayed.
The GoTo All Window has additional functionalities that can be categorized in to
- Filter
- Scope
Filters in Go To All Window in Visual Studio
You can narrow your search in the Go To All Window by applying the predefined filters. Following are the supported filters in the Go To All Window
Filter Description |
Go to the specified line number in your editor |
Go to the specified file in your editor |
Go to the specified, recently visited file in your editor |
Go to the specified type in your editor |
Go to the specified member in your editor |
Go to the specified symbol in your editor |
Filtering by Scope in Go To All Window in Visual Studio
When filtering in the Go To All window in Visual Studio, you can decide on applying the following scopes
- Search current document only
- Search external documents + one found in the project solution.
How to Customize the Go To All Window in Visual Studio?
To customize the Go To All Window in Visual Studio, use the settings icon in the “Go To All” dialog when it is displayed. You will be provided with 3 options for customization.
- Center Window
- This option lets you to display the Go To All window in the center of the editor instead of top right corner of your editor.
- Show Details
- When this option is enabled, it will display the documentation comments etc. in the Go To All window.
- Use Preview Tab
- When this is enabled, you will immediately see the selected item in the IDE’s preview tab.