ListViewGroupCollection::RemoveAt Method (Int32)

 

Removes the ListViewGroup at the specified index within the collection.

Namespace:   System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

public:
virtual void RemoveAt(
	int index
) sealed

Parameters

index
Type: System::Int32

The index within the collection of the ListViewGroup to remove.

Use this method to remove a group from the collection when you have the index of the group within the collection. Note that removing groups from the ListView::Groups collection does not remove items from the ListView control.

To remove a group using a reference to the object, use the Remove method instead. To remove all the groups from the collection, use the Clear method. When you remove an item from the collection, the indexes change for subsequent items in the collection. All information about the removed item is deleted.

.NET Framework
Available since 2.0
Return to top
Show: