CodeCatchClauseCollection.Add(CodeCatchClause) Metod

Definition

Lägger till det angivna CodeCatchClause objektet i samlingen.

public:
 int Add(System::CodeDom::CodeCatchClause ^ value);
public int Add(System.CodeDom.CodeCatchClause value);
member this.Add : System.CodeDom.CodeCatchClause -> int
Public Function Add (value As CodeCatchClause) As Integer

Parametrar

value
CodeCatchClause

Objektet som CodeCatchClause ska läggas till.

Returer

Indexet där det nya elementet infogades.

Exempel

I följande exempel visas hur du lägger till ett CodeCatchClause objekt i instansen CodeCatchClauseCollection .

// Adds a CodeCatchClause to the collection.
collection.Add( new CodeCatchClause("e") );
' Adds a CodeCatchClause to the collection.
collection.Add(New CodeCatchClause("e"))

Gäller för

Se även