0

I am trying to access the Output Window and ErrorList member of ToolWindows of an EnvDTE.DTE object. It seems that these members exist in EnvDTE80.DTE2 only. Is there a way for me to access them without type casting back to DTE2 type?

CaTx
  • 1,421
  • 4
  • 21
  • 42

1 Answers1

1

EnvDTE.Window.Object returns the inner object of the toolwindow. You can use code similar to this, that gets the toolbox:

Dim objWindow As EnvDTE.Window
Dim objToolBox As EnvDTE.ToolBox

objWindow = dte.Windows.Item(EnvDTE.Constants.vsext_wk_Toolbox)
objToolBox = CType(objWindow.Object, EnvDTE.ToolBox)

See HOWTO: Get the programmable inner object of a toolwindow

Carlos Quintero
  • 4,300
  • 1
  • 11
  • 18