Package.ToolboxUpgraded Event
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Event generated whenever Visual Studio upgrades its Toolbox.
public:
event EventHandler ^ ToolboxUpgraded;
public event EventHandler ToolboxUpgraded;
member this.ToolboxUpgraded : EventHandler
Public Event ToolboxUpgraded As EventHandler
Event Type
Remarks
The Visual Studio IDE generates a ToolboxUpgraded event whenever one or more of the following situations occur:
The version number of an existing Toolbox item provider supplied by a VSPackage changes.
The Toolbox item provider version number of a VSPackage is set by the version argument of the ProvideToolboxItemsAttribute object that must be applied to any VSPackage providing Toolbox items.
A VSPackage programmatically generates a ToolboxInitialized event through the Visual Studio SDK by a VSPackage calling ResetDefaults with PKGRF_TOOLBOXSETUP.
IVsUIShell uiShell = (IVsUIShell)GetService(typeof(SVsUIShell)); IVsPackage pkg = GetService(typeof(Package)) as IVsPackage; pkg.ResetDefaults((uint)__VSPKGRESETFLAGS. PKGRF_TOOLBOXSETUP);
For more information on handling a ToolboxInitialized event and providing custom Toolbox items, see Advanced Toolbox Control Development.