Groups | Blog | Home
all groups > visual studio .net ide > march 2004 >

visual studio .net ide : Collapse to Definitions on Open?


Dave Veeneman
3/29/2004 11:53:42 AM
Is there a simple way to force a document to Collapse to Definitions on
open? The item in Options collapses the region blocks-- I want to collapse
one step further.

I tried writing a simple macro in the DocumentOpening event of the Macros
IDE. Unfortunately, it did nothing. My next change vaporizes the running
instance of VS.Net.

Can someone provide me the correct macro code to do this? Is there an easier
way to do it?

--
Thanks in advance,

Dave Veeneman
Chicago

Dave Veeneman
5/19/2004 9:55:09 AM
I finally got back to this issue, and here is what I did: Record a one-line
macro that makes a call to CollapseToDefinitions (select the item on the
Edit Menu). Then create a DocumentEvents_DocumentOpened event handler in the
Macro IDE (go to Macro Explorer, open the macro IDE, and select the
Environment Events module in My Macros). Create a
DocumentEvents_DocumentOpened handler and move the recorded call to
CollapseToDefinitions to the event handler. Documents will now collapse to
Definitions when they are opened.

AddThis Social Bookmark Button