CodeCommentStatementCollection.Add(CodeCommentStatement) Metod

Definition

Lägger till det angivna CodeCommentStatement objektet i samlingen.

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

Parametrar

value
CodeCommentStatement

Objektet som CodeCommentStatement ska läggas till.

Returer

Indexet där det nya elementet infogades.

Exempel

I följande exempel visas hur du lägger till ett CodeCommentStatement objekt i en CodeCommentStatementCollection instans.

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

Gäller för

Se även