CodeAttributeArgumentCollection.Add(CodeAttributeArgument) Método

Definición

Agrega el objeto especificado CodeAttributeArgument a la colección.

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

Parámetros

value
CodeAttributeArgument

Objeto CodeAttributeArgument que se va a agregar.

Devoluciones

Índice en el que se insertó el nuevo elemento.

Ejemplos

En el ejemplo siguiente se muestra cómo agregar un CodeAttributeArgument objeto a una CodeAttributeArgumentCollection instancia de .

// Adds a CodeAttributeArgument to the collection.
collection.Add( new CodeAttributeArgument("Test Boolean Argument", new CodePrimitiveExpression(true)) );
' Adds a CodeAttributeArgument to the collection.
collection.Add(New CodeAttributeArgument("Test Boolean Argument", New CodePrimitiveExpression(True)))

Se aplica a

Consulte también