ListView.CheckedListViewItemCollection.ContainsKey(String) 方法

定義

判斷具有指定索引鍵的資料行是否包含在集合中。

public:
 virtual bool ContainsKey(System::String ^ key);
public virtual bool ContainsKey (string key);
abstract member ContainsKey : string -> bool
override this.ContainsKey : string -> bool
Public Overridable Function ContainsKey (key As String) As Boolean

參數

key
String

要搜尋的項目名稱。

傳回

Boolean

若具有指定機碼的項目包含在集合中,則為 true;否則為 false

例外狀況

擁有人 ListView 位於虛擬模式中。

備註

NameListViewItem 屬性會對應至 中 ListView.CheckedListViewItemCollection 專案的索引鍵。

適用於