ListCollectionView.GroupDescriptions Property

Definition

Gets a collection of GroupDescription objects that describe how the items in the collection are grouped in the view.

C#
public override System.Collections.ObjectModel.ObservableCollection<System.ComponentModel.GroupDescription> GroupDescriptions { get; }

Property Value

A collection of GroupDescription objects that describe how the items in the collection are grouped in the view.

Examples

The following example shows how to use this property:

C#
// This groups the items in the view by the property "Category"
PropertyGroupDescription groupDescription = new PropertyGroupDescription();
groupDescription.PropertyName = "Category";
listingDataView.GroupDescriptions.Add(groupDescription);

For the complete example, see Data Binding Demo.

Remarks

Note

This property can only be set by accessing the collection object and using its various methods such as Add. The property to access the collection object itself is read-only; the collection itself is read/write.

Applies to

Product Versions
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9, 10

See also