Search code examples
visual-studioinstallationcode-folding

Visual Studio Setup when first viewing a page


Is there a way to setup visual studio 2008 to automatically collapse regions/functions/methods when the code behind is first opened?


Solution

  • In Visual Studio 2010 this seems to auto collapse regions but not methods, classes, etc:

    Tools -> Options -> Text Editor -> C# -> Advanced -> Check "Enter Outlining mode when files open".

    I use the short-cut Ctrl + M, L to toggle collapsed regions.