CodeAttributeArgumentCollection.Add(CodeAttributeArgument) Metodo

Definizione

Aggiunge l'oggetto specificato CodeAttributeArgument all'insieme.

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

Parametri

value
CodeAttributeArgument

Oggetto CodeAttributeArgument da aggiungere.

Valori restituiti

Indice in corrispondenza del quale è stato inserito il nuovo elemento.

Esempio

Nell'esempio seguente viene illustrato come aggiungere un CodeAttributeArgument oggetto a un'istanza CodeAttributeArgumentCollection di .

// 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)))

Si applica a

Vedi anche