Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Find a file by name in Visual Studio Code

How can I find a file by name in Visual Studio Code?

A Visual Studio shortcut I'm used to is CTRL+,, but it does not work here.

like image 624
Nenad Avatar asked Sep 18 '15 09:09

Nenad


People also ask

How do I search for a filename in VS Code?

VS Code allows you to quickly search over all files in the currently opened folder. Press Ctrl+Shift+F and enter your search term. Search results are grouped into files containing the search term, with an indication of the hits in each file and its location.

How do I search for files by name?

Press the Windows key on your keyboard, then type part or all the file name (A) you want to find. See the search tips section for tips on searching for files.

How do I find a file in Visual Studio?

Find in Files allows you to search a specified set of files. The matches Visual Studio finds are listed in the Find Results window in the IDE. How the results appear depends on the options you choose on the Find in Files tab of the Find and Replace dialog box.


2 Answers

When you have opened a folder in a workspace you can do Ctrl+P (Cmd+P on Mac) and start typing the filename, or extension to filter the list of filenames

if you have:

  • plugin.ts
  • page.css
  • plugger.ts

You can type css and press enter and it will open the page.css. If you type .ts the list is filtered and contains two items.

like image 67
Dick van den Brink Avatar answered Sep 22 '22 01:09

Dick van den Brink


Press Ctl+T will open a search box. Delete # symbol and enter your file name.

like image 23
rajeev pani.. Avatar answered Sep 25 '22 01:09

rajeev pani..