Contents in a RadPane

2 posts, 0 answers
  1. NickZ
    NickZ avatar
    45 posts
    Member since:
    Apr 2009

    Posted 13 Jul 2009 Link to this post

    Hello,  I have an issue with contents inside a radpane. 

    Code 1
    <telerikDocking:RadPane x:Name="Pane01" Header="ISHTA Committed">     
        <telerikDocking:RadPane.Content>    
            <StackPanel x:Name="MainLayout">     
                <StackPanel x:Name="TopFilter" Orientation="Horizontal" Height="45" Background="Ivory" VerticalAlignment="Center">     
                    <TextBlock x:Name="AreaLabel" Text="Area" Canvas.Top="20"/>     
                    <telerikInput:RadComboBox x:Name="PeriodList" Width="75" Height="22" />    
                    <Button x:Name="FilterClick" Height="22" Width="75" Click="FilterClick_Click" Content="Filter" />    
                </StackPanel>    
                <StackPanel x:Name="GridArea">     
                    <data:RadGridView x:Name="ViewCommitted" AutoGenerateColumns="False" />    
                </StackPanel>    
            </StackPanel>    
        </telerikDocking:RadPane.Content>    
    </telerikDocking:RadPane>   
    Code 2
    <telerikDocking:RadPane x:Name="Pane01" Header="ISHTA Committed">     
        <telerikDocking:RadPane.Content>    
            <data:RadGridView x:Name="ViewCommitted" AutoGenerateColumns="False" />    
        </telerikDocking:RadPane.Content>    
    </telerikDocking:RadPane>   

    Both are pretty much same, except Code 1 has some controls (combox, botton) at the top part of the panel separated by stackpanel.  Gridview will obtain data from DB through a webservice.  The problem is Code 1 ran extremely slow.  It seems that it is stackpanel related. In Code 2, there is no stackpanel and it runs pretty normal.  I really want to add the top part on this panel.  Can anyone help me on this?  Are there any other ways to handle this situation? 

    Thanks a lot,
    Nick
  2. Kaloyan
    Admin
    Kaloyan avatar
    920 posts

    Posted 15 Jul 2009 Link to this post

    Hi NickZ,

    The problem comes from the StackPanel. The issue is that the StackPanel as a Layout control is arranging its children using infinite width and height values. This is causing a problem with the virtualization mechanism in RadGridView. I am suggestion using a Grid instead of StackPanel.

    All the best,
    Kaloyan
    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.
Back to Top