CheckedListBox.CheckedIndexCollection.Contains(Int32) 方法

定義

判斷指定的索引是否位於集合中。

public:
 bool Contains(int index);
public bool Contains (int index);
member this.Contains : int -> bool
Public Function Contains (index As Integer) As Boolean

參數

index
Int32

要放置在集合中的索引。

傳回

Boolean

如果 CheckedListBox.ObjectCollection 中的指定索引是這個集合中的項目,則為 true,否則為 false

備註

您可以使用這個方法來判斷集合中的 Items 索引是否位於集合中 CheckedIndices

適用於