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

[Solved] Grouping is not working when RadGridView is placed inside RadWindow

1 Answer 152 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
chintan
Top achievements
Rank 1
chintan asked on 30 May 2009, 07:30 PM
Hi,

    When i place RadGridView in RadWindow, it doesnt allow to Group even when "ShowGroupPanel" is set to true
As soon as i put it out of RadWindow it works...

Please help me... the XAML and C# code as follow...

<UserControl x:Class="GridViewGrouping.MainPage" 
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"   
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    xmlns:controls="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Navigation" 
    xmlns:RadGrid="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.GridView" 
    Width="700" Height="500">  
    <Grid x:Name="LayoutRoot" Background="White">  
        <StackPanel> 
            <Button Width="150" Height="30" Click="Button_Click" Content="Open RadWindow"></Button> 
        </StackPanel> 
        <controls:RadWindow x:Name="myRadWindow" > 
            <RadGrid:RadGridView x:Name="gridView" AutoGenerateColumns="True"    
            Margin="5,5,5,5" ColumnsWidthMode="None" IsReadOnly="True"   
            ScrollMode="RealTime" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"   
            IsFilteringAllowed="False" ShowGroupPanel="True" VerticalGridlinesVisibility="Visible" /> 
        </controls:RadWindow> 
    </Grid> 
</UserControl> 

namespace GridViewGrouping  
{  
    public partial class MainPage : UserControl  
    {  
        public MainPage()  
        {  
            InitializeComponent();  
 
            gridView.ItemsSource = User.LoadUsers();  
        }  
 
        private void Button_Click(object sender, RoutedEventArgs e)  
        {  
            myRadWindow.Show();  
        }  
    }  
 
    public class User  
    {  
        public int ID { get; set; }  
        public string FirstName { get; set; }  
        public string LastName { get; set; }  
 
        public static User[] LoadUsers()  
        {  
            User[] users = new User[]{  
                new User(){ID = 1, FirstName = "a", LastName="b"},  
                new User(){ID = 2,FirstName = "aa", LastName="bb"},  
                new User(){ID = 3,FirstName = "aaa", LastName="bbb"},  
                new User(){ID = 4,FirstName = "aa", LastName="bbb"},  
                new User(){ID = 5,FirstName = "aaa", LastName="bb"},  
                new User(){ID = 6,FirstName = "aaa", LastName="bb"},  
            };  
 
            return users;  
        }  
 
    }  
} 

1 Answer, 1 is accepted

Sort by
0
Accepted
Vlad
Telerik team
answered on 02 Jun 2009, 06:58 AM
Hi,

I've attached modified version of your project with our latest Silverlight 3 binaries where this problem is fixed.

All the best,
Vlad
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
GridView
Asked by
chintan
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Share this question
or