ListBox.IntegerCollection.Remove(Int32) 方法

定義

ListBox.IntegerCollection 中移除指定的整數。

public:
 void Remove(int item);
public void Remove (int item);
member this.Remove : int -> unit
Public Sub Remove (item As Integer)

參數

item
Int32

要從 ListBox.IntegerCollection 移除的整數。

備註

當您從 ListBox.IntegerCollection 中移除整數時,索引會變更集合中後續整數的索引。 已刪除已移除整數的所有資訊。 您可以使用 Remove 方法來從清單中移除特定專案,方法是指定要從清單中移除的實際專案。 若要指定要移除的整數索引,而不是整數本身,請使用 RemoveAt 方法。

如果整數不在 中 ListBox.IntegerCollection ,則這個方法不會執行任何動作。

適用於