Freigeben über


CodeCommentStatementCollection.Insert-Methode

Fügt ein CodeCommentStatement am angegebenen Index in die Auflistung ein.

Namespace: System.CodeDom
Assembly: System (in system.dll)

Syntax

'Declaration
Public Sub Insert ( _
    index As Integer, _
    value As CodeCommentStatement _
)
'Usage
Dim instance As CodeCommentStatementCollection
Dim index As Integer
Dim value As CodeCommentStatement

instance.Insert(index, value)
public void Insert (
    int index,
    CodeCommentStatement value
)
public:
void Insert (
    int index, 
    CodeCommentStatement^ value
)
public void Insert (
    int index, 
    CodeCommentStatement value
)
public function Insert (
    index : int, 
    value : CodeCommentStatement
)

Parameter

  • index
    Der nullbasierte Index, an dem das Element eingefügt werden soll.

Beispiel

' Inserts a CodeCommentStatement at index 0 of the collection.
collection.Insert(0, New CodeCommentStatement("Test comment"))
// Inserts a CodeCommentStatement at index 0 of the collection.
collection.Insert( 0, new CodeCommentStatement("Test comment") );
// Inserts a CodeCommentStatement at index 0 of the collection.
collection->Insert( 0, gcnew CodeCommentStatement( "Test comment" ) );
// Inserts a CodeCommentStatement at index 0 of the collection.
collection.Insert(0, new CodeCommentStatement("Test comment"));

Plattformen

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

.NET Framework unterstützt nicht alle Versionen sämtlicher Plattformen. Eine Liste der unterstützten Versionen finden Sie unter Systemanforderungen.

Versionsinformationen

.NET Framework

Unterstützt in: 2.0, 1.1, 1.0

Siehe auch

Referenz

CodeCommentStatementCollection-Klasse
CodeCommentStatementCollection-Member
System.CodeDom-Namespace
Add