
Professional Visual Studio 2005 (2006) [eng]
.pdf



Tips, Hacks, and Tweaks
Ever wondered if you can color-code different code files other than the ones supplied by Visual Studio 2005? Maybe you wished you could paint vertical guidelines on your code editor to ensure that your code blocks are lining up the way you want them to. What about those of you using dual-monitor setups — is there a way to manage the layout of the IDE to use them effectively?
These questions and others are answered in this chapter, where you’ll dive into the Windows registry and play around with different settings to achieve exactly the system you want. In addition, you’ll learn some techniques that will reduce the tedium of performing common tasks by replacing them with keyboard shortcuts and lesser-known features of the IDE.
IDE Shor tcuts
The integrated development environment of Visual Studio 2005 is a perfect place to start. The next set of tips let you in on features that are either undocumented or often overlooked in the documentation to the degree that you will likely never notice them.
The Open With Dialog
Visual Studio comes with a number of built-in editors, and it tries to open each file type with the appropriate editor. There are editors for XML and HTML as well as a general code editor for Visual Basic and C# and other languages, and specialized editors for visual form design, binary files, and resource files.
What you may not be aware of is that you can easily choose a different editor for a file. To open a file with a different editor, right-click its entry in the Solution Explorer and choose the Open With command from the context menu. This displays the Open With dialog (shown in Figure 40-1), in which you can choose from the various editors registered in Visual Studio 2005.





