다음을 통해 공유


CommaDelimitedStringCollection.Insert(Int32, String) 메서드

정의

지정된 인덱스에서 컬렉션에 문자열 요소를 추가합니다.

public:
 void Insert(int index, System::String ^ value);
public void Insert(int index, string value);
override this.Insert : int * string -> unit
Public Sub Insert (index As Integer, value As String)

매개 변수

index
Int32

새 요소를 추가할 컬렉션의 인덱스입니다.

value
String

컬렉션에 추가할 새 요소의 값입니다.

예제

다음 코드 예제에서는 메서드를 사용 하는 방법을 보여 줍니다 Insert . 이 코드 예제는 클래스 개요에 제공된 더 큰 예제의 CommaDelimitedStringCollection 일부입니다.

// Insert a new element in the collection.
myStrCollection.Insert(myStrCollection.Count, "userNameX");
' Insert a new element in the collection.
myStrCollection.Insert(myStrCollection.Count, "userNameX")

설명

이 메서드를 IsModified 사용 하면 속성을 설정 true합니다.

적용 대상