RowDefinitionCollection.Insert(Int32, RowDefinition) 메서드
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
에 RowDefinition 지정된 인덱스 위치에 삽입합니다 RowDefinitionCollection.
public:
virtual void Insert(int index, System::Windows::Controls::RowDefinition ^ value);
public void Insert(int index, System.Windows.Controls.RowDefinition value);
abstract member Insert : int * System.Windows.Controls.RowDefinition -> unit
override this.Insert : int * System.Windows.Controls.RowDefinition -> unit
Public Sub Insert (index As Integer, value As RowDefinition)
매개 변수
- index
- Int32
항목이 삽입되는 컬렉션 내의 위치입니다.
- value
- RowDefinition
삽입할 항목입니다 RowDefinition .
구현
예외
index가 .에서 유효한 인덱스가 아닌 경우 IList
예제
다음 예제에서는 메서드를 사용하여 내의 InsertRowDefinition 특정 index 위치에 삽입하는 방법을 보여 줍니다 RowDefinitionCollection.
private void insertRowAt(object sender, RoutedEventArgs e)
{
rowDef1 = new RowDefinition();
grid1.RowDefinitions.Insert(grid1.RowDefinitions.Count, rowDef1);
tp1.Text = "RowDefinition added at index position " + grid1.RowDefinitions.IndexOf(rowDef1).ToString();
}
Private Sub insertRowAt(ByVal sender As Object, ByVal e As RoutedEventArgs)
Dim rowDef1 As New RowDefinition
grid1.RowDefinitions.Insert(grid1.RowDefinitions.Count, rowDef1)
tp1.Text = "RowDefinition added at index position " + grid1.RowDefinitions.IndexOf(rowDef1).ToString()
End Sub
전체 샘플을 보려면 방법: ColumnDefinitionsCollections 및 RowDefinitionsCollections를 사용하여 열 및 행 조작을 참조하세요.
설명
RowDefinitionCollection 는 0부터 시작하는 인덱싱 시스템을 사용합니다.