Quick way to open files in Visual Studio IDE

In 7.0 and later you can simply and quickly open files by going to the Find combo in the toolbar, and type

>open c:\goo\bar.cpp

The pathname will even auto-complete as you type! Even the command name (“open“ in this case) will auto-complete. You will probably find other handy commands in there by experimenting.

Comments (14)
  1. I suppose you are referring to the Command Window? Because in my 7.0, nothing happens when I type that phrase in the Find combo.



  2. Fabrice says:

    Dennis, make sure you typed in the > before open.

  3. Ryan Heath says:

    Nice feature!

    Guess i’ll use ctrl+D more often now 🙂

  4. You get an error if the filename contain spaces 🙁

  5. Fabrice says:

    Thomas, it works fine with VS 2003. Quotes get added automagically.

  6. Andy Pennell says:

    Thought I generally dont like to recommend old products, VC6 has a simpler version. In the Find edit control, type a filename then press Ctrl-Alt-G to open the file. You don’t get auto completion. This is the FileGoTo command if you want to customize the keystroke.

  7. Bradley Grainger says:

    If you’re opening a file that is part of the solution, press Ctrl+D, type the filename (no path needed), then press Ctrl+Shift+G. Very handy if you have hundreds of uniquely-named files spread across dozens of folders in the one solution.

  8. John Wood says:

    Isn’t it quicker to simply press Ctrl+O and then type in the filename? Seems like fewer keystrokes to me 🙂

  9. Fabrice says:

    Wow, John! You’re absolutely right! This is the best discovery I ever heard of! :))

  10. Daniel says:

    The nice thing of Ctrl+Shift+G in VC6 is, that it even works in the text editor if the cursor is above a filename/path (either quoted by "" or by <>).

    Any idea how to get this back in VC.NET?

  11. Waqqas Farooq says:

    alternative (if you don’t like typing ‘open’):

    1. ctrl + d

    2. >of myfile.txt

  12. Filip says:

    Extensions don’t work with the express editions. I use AutoHotKey for this, the script is as follows:


    SetTitleMatchMode, 2

    IfWinActive, Visual C++

       Send ^d>of{Space}


    …which translates Ctrl+Shift+T to the sequence Ctrl+D, ">of ".

    Thanks very much for the ">of " trick, that’s new to me!

Comments are closed.

Skip to main content