共用方式為


ColumnHeader.Index 屬性

定義

用這欄的控制ListView.ColumnHeaderCollection點取得位置ListView

public:
 property int Index { int get(); };
[System.ComponentModel.Browsable(false)]
public int Index { get; }
[<System.ComponentModel.Browsable(false)>]
member this.Index : int
Public ReadOnly Property Index As Integer

屬性值

欄位標頭在所包含控制項中ListView.ColumnHeaderCollectionListView以零為基礎的索引。

屬性

備註

此屬性的值不一定對應於欄位標頭 ListView在 中當前的視覺位置。 這可能是因為使用者在執行時(當屬性 AllowColumnReorder 設定為 true時)重新排序欄位標頭。 若 不 ColumnHeader 包含在控制 ListView 範圍內,該屬性會回傳 -1 值。

適用於

另請參閱