Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

DesignerVerbCollection::AddRange Method (array<DesignerVerb^>^)

 

Adds the specified set of designer verbs to the collection.

Namespace:   System.ComponentModel.Design
Assembly:  System (in System.dll)

public:
void AddRange(
	array<DesignerVerb^>^ value
)

Parameters

value
Type: array<System.ComponentModel.Design::DesignerVerb^>^

An array of DesignerVerb objects to add to the collection.

Exception Condition
ArgumentNullException

value is null.

The following code example demonstrates how to add an array of DesignerVerb objects to a DesignerVerbCollection.

// Adds an array of DesignerVerb objects to the collection.
array<DesignerVerb^>^ verbs = {
   gcnew DesignerVerb( "Example designer verb", gcnew EventHandler( this, &Class1::ExampleEvent ) ),
   gcnew DesignerVerb( "Example designer verb", gcnew EventHandler( this, &Class1::ExampleEvent ) )};
collection->AddRange( verbs );

// Adds a collection of DesignerVerb objects to the collection.
DesignerVerbCollection^ verbsCollection = gcnew DesignerVerbCollection;
verbsCollection->Add( gcnew DesignerVerb( "Example designer verb", gcnew EventHandler( this, &Class1::ExampleEvent ) ) );
verbsCollection->Add( gcnew DesignerVerb( "Example designer verb", gcnew EventHandler( this, &Class1::ExampleEvent ) ) );
collection->AddRange( verbsCollection );

.NET Framework
Available since 1.1
Return to top
Show:
© 2017 Microsoft