This is a migrated thread and some comments may be shown as answers.

IsGroupable=false is ignored

1 Answer 53 Views
GridView
This is a migrated thread and some comments may be shown as answers.
André
Top achievements
Rank 1
André asked on 18 Apr 2012, 06:01 PM
Hi,

I am using the example I found here to dinamically insert values into RadGridView. However, this example does not allow controling the properties of the generated columns like "IsFilterable" or "IsGroupable".
To implement this functionality, I modified the RadGridView to allow the indication of Column Definitions.

When the ColumnDefinitions property is changed, the following code is executed:
static void ColumnDefinitionsChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
        {
            var gridView = sender as i9rGridView;
 
            gridView.Columns.Clear();
 
            var columnDefinitions = e.NewValue as ObservableCollection<IAttributeDefinition>;
            if (columnDefinitions != null && columnDefinitions.Count > 0)
            {
                gridView.AutoGenerateColumns = false;
                foreach (var columnDefinition in columnDefinitions)
                {
                    gridView.Columns.Add(new GridViewDataColumn() { HeaderCellStyle = Application.Current.Resources["GridViewHeaderCellStyle"] as Style, UniqueName = columnDefinition.Code, Header = columnDefinition.Text, DataType = columnDefinition.DataType, IsReadOnly = columnDefinition.AccessLevel != AccessLevel.EDITABLE ? true : false, IsVisible = columnDefinition.AccessLevel != AccessLevel.INVISIBLE ? true : false, IsGroupable = false });
                }
            }
        }

All the properties work like I want but "IsGroupable = false" is ignored and all the columns allow grouping.

How can I solve this issue?

1 Answer, 1 is accepted

Sort by
0
Chetan
Top achievements
Rank 1
answered on 31 Oct 2013, 11:54 AM
Hi André,

Have you got solution?

I am having same problem with latest build
also
<telerik:GridViewDataColumn DataMemberBinding="{Binding Name}" IsGroupable="False">
does  not work as given in
http://www.telerik.com/community/forums/silverlight/gridview/disable-groupby-option-in-gridview.aspx
please help
Tags
GridView
Asked by
André
Top achievements
Rank 1
Answers by
Chetan
Top achievements
Rank 1
Share this question
or