Thursday, August 2, 2012

Command Window is not available in Visual Studio Express editions

 

As other users have noticed in posts like this one, Command Window is a toolwindow that isn’t available in Visual Studio editions to be explicitly displayed by the user.  The menu commands used to display the window are not available.

Fortunately, there are workarounds.

Immediate Window is another related toolwindow that can be used to display variables’ values, evaluate expressions, and to execute commands. The Immediate Window is automatically displayed when entering Debug mode. It can also be displayed on-demand by using the Debug/Windows/ImmediateWindow (Ctrl+D, I) menu item.

Command Window displays automatically a “>” prompt and the user only has to type command names. To execute commands in Immediate Window, the user has to explicitly type the commands by prefixing them with “>”. Full Intellisense support is available here, same as in Command Window. Pre-defined aliases also work fine (of course, trying to execute commands that don’t exist, aka forcing the display of CommandWindow won’t work).

image

A second workaround is to use the Find combobox.

First, make sure the Find combobox is displayed in the Standard toolbar (in Visual Studio 2012 this has been hidden with the command bar reduction work, so you’ll have to use the quick customize menus to bring it back)

image

Then, in the Find combo you can type commands by starting them with “>”, and the full functionality of Command Window will be available there (with Intellisense, aliases like “of”, etc).

image

The only Professional feature related to Command Window that can’t be workaround in Express editions is redirecting the output to a file. The Tools.LogCommandWindowOutput (“log” alias) and Tools.ImmediateMode (“immed” alias) are not available either. Anyway, you won’t need the last one since you are already in Immediate Window, can manually display the toolwindow or execute “>Debug.Immediate” instead from Find combo.

No comments: