Help2 Interface
Visual Studio 2005
The interface that supports Document Explorer.
Namespace: Microsoft.VisualStudio.VSHelp80
Assembly: Microsoft.VisualStudio.VSHelp80 (in microsoft.visualstudio.vshelp80.dll)
Assembly: Microsoft.VisualStudio.VSHelp80 (in microsoft.visualstudio.vshelp80.dll)
Help2 supports How Do I, Search, and Favorites. It is the main entry point for accessing Document Explorer (Dexplorer.exe).
How you obtain the Help2 object depends on the application.
In non-VSPackages:
-
The Help2 object is a child of DTE in its object hierarchy and can be accessed by using the late-bound DTE.Help property. To access Help2 in an application that is not an add-in or a macro, you must obtain an instance of DTE, which is illustrated by the following example:
EnvDTE.DTE dte; dte = (EnvDTE.DTE)System.Runtime.InteropServices.Marshal.GetActiveObject("VisualStudio.DTE.8.0"); Object helpobj = dte.Help; -
In an add-in you can obtain the Help2 object directly:
Microsoft.VisualStudio.VSHelp80.Help2 help2 = (Microsoft.VisualStudio.VSHelp80.Help2)dte.GetObject("Help2");
In a VSPackage:
-
You obtain the Help2 object through SVsHelp service:
Microsoft.VisualStudio.VSHelp80.Help2 help2; // Obtain the Help2 object from SVsHelp service. help2 = (Microsoft.VisualStudio.VSHelp80.Help2)
this.GetService(typeof(Microsoft.VisualStudio.VSHelp.SVsHelp));