CodeCatchClauseCollection.Add(CodeCatchClause) Metod
Definition
Viktigt
En del information gäller för förhandsversionen av en produkt och kan komma att ändras avsevärt innan produkten blir allmänt tillgänglig. Microsoft lämnar inga garantier, uttryckliga eller underförstådda, avseende informationen som visas här.
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"))