CodeParameterDeclarationExpressionCollection.Insert Metod

Definition

Infogar den angivna CodeParameterDeclarationExpression i samlingen vid det angivna indexet.

public:
 void Insert(int index, System::CodeDom::CodeParameterDeclarationExpression ^ value);
public void Insert(int index, System.CodeDom.CodeParameterDeclarationExpression value);
member this.Insert : int * System.CodeDom.CodeParameterDeclarationExpression -> unit
Public Sub Insert (index As Integer, value As CodeParameterDeclarationExpression)

Parametrar

index
Int32

Det nollbaserade index där det angivna objektet ska infogas.

Exempel

I följande exempel visas hur du använder Insert metoden för att lägga till ett CodeParameterDeclarationExpression objekt i en CodeParameterDeclarationExpressionCollection.

// Inserts a CodeParameterDeclarationExpression at index 0
// of the collection.
collection.Insert( 0, new CodeParameterDeclarationExpression(typeof(int), "testIntArgument") );
' Inserts a CodeParameterDeclarationExpression at index 0 
' of the collection.
collection.Insert(0, New CodeParameterDeclarationExpression(GetType(Integer), "testIntArgument"))

Gäller för

Se även