Share via


CodeCommentStatementCollection.Add(CodeCommentStatement) Método

Definición

Agrega a la colección el objeto CodeCommentStatement especificado.

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

Parámetros

value
CodeCommentStatement

Objeto CodeCommentStatement que se agrega.

Devoluciones

Índice donde se insertó el nuevo elemento.

Ejemplos

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

// Adds a CodeCommentStatement to the collection.
collection->Add( gcnew CodeCommentStatement( "Test comment" ) );
// Adds a CodeCommentStatement to the collection.
collection.Add( new CodeCommentStatement("Test comment") );
' Adds a CodeCommentStatement to the collection.
collection.Add(New CodeCommentStatement("Test comment"))

Se aplica a

Consulte también