ToolboxItem.CreateComponentsCore Method (IDesignerHost, IDictionary)

Creates an array of components when the toolbox item is invoked.

Namespace: System.Drawing.Design
Assembly: System.Drawing (in system.drawing.dll)

protected:
virtual array<IComponent^>^ CreateComponentsCore (
	IDesignerHost^ host, 
	IDictionary^ defaultValues
)
protected IComponent[] CreateComponentsCore (
	IDesignerHost host, 
	IDictionary defaultValues
)
protected function CreateComponentsCore (
	host : IDesignerHost, 
	defaultValues : IDictionary
) : IComponent[]
Not applicable.

Parameters

host

The designer host to use when creating components.

defaultValues

A dictionary of property name/value pairs of default values with which to initialize the component.

Return Value

An array of created IComponent objects.

If host is not a null reference (Nothing in Visual Basic), the CreateComponentsCore method adds the new components to the designer.

The following code example demonstrates the use of the CreateComponentsCore method in a class derived from ToolboxItem for a custom toolbox item implementation. This code example is part of a larger example provided for the ToolboxItem class.

No code example is currently available or this language may not be supported.

Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0

Community Additions

ADD
Show: