Welcome to MSDN Blogs Sign in | Join | Help

Mark Schmidt's Abode

On Programming, Writing, Gaming, Fitness, Life

News

  • Have a Question?

    Click here to chat with me

    XBox Live GamerTag


    Twitter



    The Mark Cam


    My MoBlog

    www.flickr.com
    This is a Flickr badge showing public photos from codepunk. Make your own badge here.

    Community-Credit

Visual Studio .NET 2003 Tip o' the day

Ok, I'm pulling another little tip out of my big grab bag of useful programmer tricks. These one is quite simple to do and I use it all the time. How many times do you have to go to your local file system to look at your solution's files? For me, it's all the time. Sure you could create a shortcut on your quicklaunch bar to your Visual Studio Projects folder but what if your SCCP places your source somewhere else? Here's what I do:

1. Open up Visual Studio .NET
2. From the main menu, click on Tools -> External Tools
3. Click the Add button
4. Enter the following values in the following fields

  • Title: Explore Here
  • Command: explorer.exe
  • *Arguments: $(SolutionDir)
  • *Initial Directory: $(SolutionDir)

* You can also use $(ProjectDir) but you'll have to highlight the project in Solution Explorer first.
5. Click on OK to close the External Tools dialog.

Now whenever you are working on a project, just click on Tools -> Explore Here and you'll get just what you asked for. Even better, make it a button on your toolbar for even easier access.

Posted: Friday, September 10, 2004 11:27 AM by markhsch

Comments

Confused Guy said:

Im confused. Why not just click "Show All Files" in the solution explorer?

Signed
Confused Guy
# September 10, 2004 12:02 PM

Mark Schmidt[MSFT] said:

I can think of several reasons:

1. Show All Files works on a project level. If you have a solution with several projects each in their own directories, you can't see any files in the main solution directory.

2. You have to click the Show All Files button for each project in your solution.

3. How would I run an Explorer command on the files? e.g. Send To (compressed folder, email recipient), or mark as Read Only.

4. The Show All button doesn't even show for C++ projects (haven't checked managed C++ though).

I'm sure I can sit here and think or more all day, but that should be enough.
# September 10, 2004 12:21 PM

Tommy Rush said:

Cool tip. Thanks!
# September 10, 2004 12:36 PM

Chris Haas said:

So simple and yet so cool. Thanks.
# September 10, 2004 1:06 PM

Jeremy Boschen said:

yes, good tip. I use something similar for launching a command prompt w/ a build environment enabled...

Title: Command Prompt Here
Command: %COMSPEC%
Args: /K "SET PROMPT=# & C: & CD $(SolutionDir) & "C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\Tools\vsvars32.bat""
# September 10, 2004 1:26 PM

Paul Speranza said:

Thanks. I never new you could do that.
# September 11, 2004 6:32 AM
Leave a Comment

(required) 

(required) 

(optional)

(required) 

  
Enter Code Here: Required

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Page view tracker