To collapse all classes/functions/subs, press CTRL + M, CTRL + O. And to expand them all again, just press CTRL + M, CTRL + P.
I always thought that visual studio should have these 2 shortcuts built directly into a right hand mouse button context menu so that users can collapse and expand their source code more easily instead of remembering another set of shortcuts by heart. Even my favorite php ide phped has that built in!
Brandon Mize says
Use CTRL + M, CTRL + L to expand instead. Your method disables outlining.