NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

IContainer.Add (IComponent, String)

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

[Visual Basic]
Overloads Sub Add( _
   ByVal component As IComponent, _
   ByVal name As String _
)
[C#]
void Add(
   IComponent component,
   string name
);
[C++]
void Add(
   IComponent* component,
   String* name
) = 0;
[JScript]
function Add(
   component : IComponent,
   name : String
);

Parameters

component
The IComponent to add.
name
The name to assign to component; or a null reference object to skip the name assignment.

Return Value

None.

Exceptions

Exception Type Condition
InvalidOperationException name is already used by another component in the same container.

Remarks

The components within a container may or may not be named. If a component is given a name, the name must be unique among all the components within the container.

See Also

IContainer Interface | IContainer Members | System.ComponentModel Namespace | IContainer.Add Overload List