IContainer.Add IContainer.Add IContainer.Add IContainer.Add Method

Definition

Adds the specified component to the IContainer.

Overloads

Add(IComponent) Add(IComponent) Add(IComponent) Add(IComponent)

Adds the specified IComponent to the IContainer at the end of the list.

Add(IComponent, String) Add(IComponent, String) Add(IComponent, String) Add(IComponent, String)

Adds the specified IComponent to the IContainer at the end of the list, and assigns a name to the component.

Add(IComponent) Add(IComponent) Add(IComponent) Add(IComponent)

Adds the specified IComponent to the IContainer at the end of the list.

public:
 void Add(System::ComponentModel::IComponent ^ component);
public void Add (System.ComponentModel.IComponent component);
abstract member Add : System.ComponentModel.IComponent -> unit
Public Sub Add (component As IComponent)
Parameters

Remarks

The new IComponent is added at the end of the list.

Add(IComponent, String) Add(IComponent, String) Add(IComponent, String) Add(IComponent, String)

Adds the specified IComponent to the IContainer at the end of the list, and assigns a name to the component.

public:
 void Add(System::ComponentModel::IComponent ^ component, System::String ^ name);
public void Add (System.ComponentModel.IComponent component, string name);
abstract member Add : System.ComponentModel.IComponent * string -> unit
Public Sub Add (component As IComponent, name As String)
Parameters
name
String String String String

The unique, case-insensitive name to assign to the component.

-or-

null that leaves the component unnamed.

Remarks

The new IComponent is added at the end of the list.

Notes to Implementers

When you inherit from Add(IComponent), you must assure that name, if not null, is unique for this IContainer.

Applies to