Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Event generated whenever Visual Studio initializes its Toolbox.
Namespace: Microsoft.VisualStudio.Shell
Assembly: Microsoft.VisualStudio.Shell.9.0 (in Microsoft.VisualStudio.Shell.9.0.dll)
Syntax
'Declaration
Protected Event ToolboxInitialized As EventHandler
'Usage
Dim handler As EventHandler
AddHandler Me.ToolboxInitialized, handler
protected event EventHandler ToolboxInitialized
protected:
event EventHandler^ ToolboxInitialized {
void add (EventHandler^ value);
void remove (EventHandler^ value);
}
JScript does not support events.
Remarks
The Visual Studio IDE generates a ToolboxInitialized event whenever one or more of the following situations occur:
A user manually resets the Toolbox by right-clicking on one of the Toolbox categories and selection Reset Toolbox.
A new VSPackage providing Toolbox items is registered.
A VSPackage programmatically generates a ToolboxInitialized event through the Visual Studio SDK by a VSPackage calling ResetDefaults with PKGRF_TOOLBOXITEMS.
IVsUIShell uiShell = (IVsUIShell)GetService(typeof(SVsUIShell)); IVsPackage pkg = GetService(typeof(Package)) as IVsPackage; pkg.ResetDefaults((uint)__VSPKGRESETFLAGS.PKGRF_TOOLBOXITEMS);
For more information on handling a ToolboxInitialized event and providing custom Toolbox items, see How to: Provide Custom Toolbox Items By Using the Managed Package Framework.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.