简体   繁体   中英

How to open a file quickly in visual studio .net

In visual studio, we can open a file in a #Include statement by right clicking the filename in include statement and then clicking "Open Document". But sometimes, when I want to open a file, I don't remember where it was in the project or where has it been included. What I do is that I open any file, add a #include statement for that file, then right-click->Open Document to open the file and then remove the #include statement that I added just to open this file.

Can someone plz tell me a more straight forward way of quickly opening a file without searching for it?

I am using Visual Studio 2008

Hit Ctrl + / to go to the "Find" combo box in the default toolbar, type >of Foo.cpp , and hit enter. of is the "open file" command and will give you autocompletion with the files in your solution.

This also works for any other system or library header files you include (eg windows.h ).

在此输入图像描述

The leading > character tells the "Find" combo box to act like the Command Window, so any commands that work in the Command Window work in the combo box as well.

Visual Assist X's "Open File in Solution" (command VAssistX.OpenFileInSolutionDialog) works great for quickly opening a file. I find it faster to use than Visual Studio's ">of" command.

See http://www.wholetomato.com/products/featureSearch.asp for a screenshot.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM