How to search for file names in Visual Studio?

Visual StudioSearchKeyboard ShortcutsVisual Studio-Mac

Visual Studio Problem Overview


In Eclipse you can search for a file in the project by pressing CTRL-SHIFT-R.

Is there a way to do this in Visual Studio?

Visual Studio Solutions


Solution 1 - Visual Studio

Just for anyone else landing on this page from Google or elsewhere, this answer is probably the best answer out of all of them.

To summarize, simply hit:

CTRL + ,

And then start typing the file name.

Solution 2 - Visual Studio

In VS2013 you can click in the solution explorer for this functionality.

The shortcut is:

ctrl + ;

To search only the names of files, and not the contents (especially in C#), uncheck these options:

Solution 3 - Visual Studio

The best option now is to install Microsoft Visual Studio add on called Productivity Power Tools (VS 2010 version, VS 2013 version).

With this comes "Solution Navigator" (alternative to Solution Explorer, with a lot of benefits).

search solution navigator

BTW, this feature is built-in into Visual Studio 2012.

Solution 4 - Visual Studio

With Visual Studio 2017, It now comes with a much better version, named “Go To All” and is bound to the keyboard shortcut CTRL + T as well as CTRL +, and includes inline filtering and “fuzzy search”

CTRL + T

CTRL + ,

Solution 5 - Visual Studio

Easily hit CTRL+SHIFT+T . This will look in the files' names.

Solution 6 - Visual Studio

In the search dropdown on the standard toolbar, you can use the "open file" macro, >of, to find files. Click in said dropdown (or hit Ctrl-D) then start typing (minus the quotes) ">of CoreEdit.cs", and you'll get a dynamic list that narrows as you type.

Solution 7 - Visual Studio

In Visual Studio 2017 you can search directly for files with Ctrl+1, Ctrl+F (Keyboard command: Edit.GoToFile).

Alternatively, you can use Ctrl+t or Ctrl+, (the Edit.GoToAll command) and start your search with f.

Solution 8 - Visual Studio

I use usysware DPack: http://www.usysware.com/dpack/

Then I just press ALT-U start typing the filename and choose the correct file. DPack also has other nice features.

enter image description here

(highlights added for screenshot)

Note: Will not work in Express editons of Visual Studio, since they don't allow plugins.

Solution 9 - Visual Studio

Since you mention ReSharper in a comment:

You can do this in ReSharper by using the "Goto File..." option (Ctrl-Shift-N or ReSharper -> Go To -> File...) in my key mappings.

Solution 10 - Visual Studio

I'd recommend PhatStudio if you're using upto VS 2012. Works pretty fast, and supports multi-word search by using "space". So to search for LoginController, you could press Alt+O and search using "Lo Con".

enter image description here

You could also use ReSharper (paid) and CodeMaid (free) to do this.

Solution 11 - Visual Studio

CTRL + P this searches for the file name your direct answer.

Solution 12 - Visual Studio

Visual Assist: link.

Install, load solution, press Shift+Alt+O, search for files in solution by substring. Try also Shift+Alt+S, for the equivalent for symbols. This addin has a bunch of completion popup and syntax colouring stuff in it that aren't to all tastes, but the code browsing features are done well and seem uncontroversial.

Judging by comments on the forums, compatibility with Resharper is something they pay attention to.

For free, try also Nifty Solution: link.

I haven't used this myself, but I use the author's Nifty Perforce plugin, and that is pretty tidy.

Solution 13 - Visual Studio

Open command window( View -> Other windows -> command window - Ctrl + W, A) type >of followed by the file name. It would start showing up the list as you type.

Solution 14 - Visual Studio

You can easily call for a window called "Navigate To" with combination ctrl + ,

Or, go to Tools and then click Navigate To

Solution 15 - Visual Studio

Visual Studio for Mac 2017 7.x.x

To search by File name:

  • + .
  • Ctrl + Shift + D

To search by Type name:

  • Ctrl + Shift + T

Your keyboard focus might have been gone to following Right side Top corner of the Visual Studio Window:

enter image description here

Solution 16 - Visual Studio

You can press ctrl+t to get a editor Get to all , in which you can type the file name to navigate to that specific file.

Solution 17 - Visual Studio

Is too simple by using the Windows Explorer search inside the project folder. Done.

Solution 18 - Visual Studio

With Visual Studio 2017 Community edition on mac, the shortcut is:

  • Cmd+Shift+D: Find by file name
  • Cmd+Shift+T: Find by type name

To see these commands, navigate to the top menu: Search > Go To

Solution 19 - Visual Studio

In Visual Studio 2008 (and probably later), the free DevExpress CodeRush Xpress add-in supplies Ctrl+Alt+F, Quick File Navigation, which searches on an exact substring in the file name or on capital letters.

(Unrelated to this answer, but note the rather more useful, Quick Navigation, Ctrl+Shift+Q, which I would have liked to have known about before now :-) )

Solution 20 - Visual Studio

Visual Studio 2019:

Menu -> Preferences -> Key Bindings -> Navigate To...

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionEdward TanguayView Question on Stackoverflow
Solution 1 - Visual StudioHannaView Answer on Stackoverflow
Solution 2 - Visual StudioJohnView Answer on Stackoverflow
Solution 3 - Visual StudiofriendView Answer on Stackoverflow
Solution 4 - Visual StudioSajeetharanView Answer on Stackoverflow
Solution 5 - Visual StudioBedairView Answer on Stackoverflow
Solution 6 - Visual StudiokirkusView Answer on Stackoverflow
Solution 7 - Visual StudioKyleView Answer on Stackoverflow
Solution 8 - Visual StudioErwinView Answer on Stackoverflow
Solution 9 - Visual StudioadrianbanksView Answer on Stackoverflow
Solution 10 - Visual StudioarvimanView Answer on Stackoverflow
Solution 11 - Visual StudioJukeView Answer on Stackoverflow
Solution 12 - Visual Studioplease delete meView Answer on Stackoverflow
Solution 13 - Visual Studiouser2645830View Answer on Stackoverflow
Solution 14 - Visual StudioEduardo AView Answer on Stackoverflow
Solution 15 - Visual StudioRandika VishmanView Answer on Stackoverflow
Solution 16 - Visual Studioshiga soumyaView Answer on Stackoverflow
Solution 17 - Visual StudioCarlossView Answer on Stackoverflow
Solution 18 - Visual StudioKes115View Answer on Stackoverflow
Solution 19 - Visual StudioMark HurdView Answer on Stackoverflow
Solution 20 - Visual StudioOz ShabatView Answer on Stackoverflow