TableLayoutRowStyleCollection.Insert(Int32, RowStyle) 方法

定義

在指定位置插入 a RowStyleTableLayoutRowStyleCollection

public:
 void Insert(int index, System::Windows::Forms::RowStyle ^ rowStyle);
public void Insert(int index, System.Windows.Forms.RowStyle rowStyle);
member this.Insert : int * System.Windows.Forms.RowStyle -> unit
Public Sub Insert (index As Integer, rowStyle As RowStyle)

參數

index
Int32

應插入的 RowStyle 以零為基礎的索引。

rowStyle
RowStyle

RowStyle 插入 TableLayoutRowStyleCollection. 其值可以是 null

備註

Insert 方法會將表格佈局重新套用到目前 TableLayoutPanel 容器中的所有控制項。

集合中儲存的樣式數量僅受限於可用記憶體。

在連續元素的集合中,例如類別, TableLayoutRowStyleCollection 插入點後的元素會向下移動以容納插入的元素。 移動元素的索引也會同步更新。

適用於

另請參閱