ListView.ListViewItemCollection
Wisej.Web.ListView ListViewItemCollection
Namespace: Wisej.Web
Assembly: Wisej.Framework (3.2.0.0)
Represents the collection of items in a ListView control.
Properties
Count
Int32: Returns the total number of items in the collection.
IsReadOnly
Boolean: Returns a value indicating whether the collection is read-only.
Item(index)
ListViewItem: Returns or sets the item at the specified index in the collection.
Throws:
ArgumentOutOfRangeException The index value is less than 0 or is greater than the number of items in the collection.
Item(key)
ListViewItem: Returns the item with the specified key from the collection.
Methods
Add(text)
Adds a new item with the specified label text to the end of the current collection.
Returns: ListViewItem. A ListViewItem that represents the item being added to the collection.
Add(key, text)
Creates a new item with the specified key and text, and adds it to the collection.
Returns: ListViewItem. The ListViewItem that was added to the collection.
Add(key, text, imageIndex)
Creates a new item with the specified key, text, and image, and adds it to the collection.
Returns: ListViewItem. The ListViewItem that was added to the collection.
Add(key, text, imageKey)
Creates a new item with the specified key, text, and image, and adds it to the collection.
Returns: ListViewItem. The ListViewItem that was added to the collection.
Add(item)
Adds a previously created item to the end of the collection.
Returns: Int32. The zero-based index value of the ListViewItem added to the collection.
Throws:
ArgumentException The item is currently assigned to another ListView.
AddRange(items)
Adds an array of previously created items to the collection.
Throws:
ArgumentNullException items is null.
ArgumentException items is the child of another ListViewItem.
Clear()
Removes all items from the collection.
Clear(dispose)
Removes all items from the collection and optionally disposes them.
Contains(item)
Determines whether the specified item is a member of the collection.
Returns: Boolean. true if the ListViewItem is a member of the collection; otherwise, false.
ContainsKey(key)
Determines whether the collection contains an item with the specified key.
Returns: Boolean. true to indicate the collection contains a ListViewItem with the specified key; otherwise, false.
CopyTo(dest, index)
Copies the entire collection into an existing array at a specified location within the array.
GetEnumerator()
Returns an enumerator that can be used to iterate through the collection.
Returns: IEnumerator<ListViewItem>. An IEnumerator that represents the ListViewItemCollection.
IndexOf(item)
Returns the index of the specified item in the collection.
Returns: Int32. The zero-based index of the item found in the ListViewItemCollection; otherwise, -1.
IndexOfKey(key)
Returns the index of the first occurrence of a item with the specified key.
Returns: Int32. The zero-based index of the first occurrence of a ListViewItem with the specified key, if found; otherwise, -1.
Insert(index, item)
Inserts an existing item into the collection at the specified location.
Throws:
ArgumentException The item is currently assigned to another ListView.
Insert(index, text)
Creates a new item with the specified text and inserts it at the specified index.
Returns: ListViewItem. The ListViewItem that was inserted in the collection.
Insert(index, key, text)
Creates a new item with the specified text and key, and inserts it into the collection.
Returns: ListViewItem. The ListViewItem that was inserted in the collection.
Insert(index, key, text, imageIndex)
Creates a new item with the specified key, text, and image, and inserts it into the collection at the specified index.
Returns: ListViewItem. The ListViewItem that was inserted in the collection.
Insert(index, key, text, imageKey)
Creates a new item with the specified key, text, and image, and inserts it into the collection at the specified index.
Returns: ListViewItem. The ListViewItem that was inserted in the collection.
Remove(item)
Removes the specified item from the collection.
RemoveAt(index)
Removes the item from the collection at a specified index.
RemoveByKey(key)
Removes the item with the specified key from the collection.
Events
CollectionChanged
CollectionChangeEventHandler Fired when the collection changes.
Last updated