Using Hide Selection
Versions Supported: 2010 Keyboard Shortcut: CTRL + M, CTRL + H Menu Command: Edit -> Outlining -> Hide Selection Tip Code: vstipEdit0036 This is a new feature in VS2010 that absolutely rocks! Let’s say you have a chunk of code like this: Notice that Outlining only allows you to collapse the entire member by default (minus sign in the upper left-hand corner). What if you want to, say, collapse the “if” statements at the top? In prior versions you were out of luck but NOW you can do it. Here’s how: Select the chunk of code you want to hide: Now either press CTRL + M, CTRL + H or go to Edit -> Outlining -> Hide Selection on your Menu Bar to get this: Congratulations! You have successfully collapsed a custom region of code!

View original here:
Using Hide Selection


