Agnes,
Have you considered creating a VS.NET macro that handles the
DocumentEvents_DocumentOpened event?
Something like (untested):
Private Sub DocumentEvents_DocumentOpened(ByVal Document As
EnvDTE.Document) Handles DocumentEvents.DocumentOpened
DTE.ExecuteCommand("Edit.CollapsetoDefinitions")
End Sub
Note you may need to use a different VS.NET event the above event is not
working as I would expect... Look in EnvironmentEvents module in the VS.NET
Macro IDE for the list of objects that support events...
Although I normally use Ctrl+M Ctrl+O (rather then right click...).
Hope this helps
Jay