Home › Forums › WPF controls › Xceed DataGrid for WPF › Avoid grouping by specific column(s)
Hi group, how can I stop (either in XAML or programmatically) a specific column from being used as a grouping criterion? E.g. let’s say I have a simple data grid like:
<xcdg:DataGridControl x:Name=”dummy” AutoCreateColumns=”False”ReadOnly=”True”> <xcdg:Column FieldName=”id” Title=”first name” Width=”30″/> <xcdg:Column FieldName=”year” Title=”year published” Width=”60″/>…</xcdg:DataGridControl>
I’d like the user to be able to group by any column (e.g. year) EXCEPT by id, which would have no meaning as this value is unique by definition. How can I do this?
Imported from legacy forums. Posted by Mathetes (had 508 views)
You can prevent all columns from being a grouping source by setting the AllowGroupModifications property of the GroupByControl to false.
Preventing a single column from being a grouping source is currently on our feature list.
Imported from legacy forums. Posted by Jenny [Xceed] (had 2703 views)