Header in RadDocking.DocumentHost

2 posts, 0 answers
  1. Gilmar
    Gilmar avatar
    19 posts
    Member since:
    Jul 2010

    Posted 07 Mar 2013 Link to this post

    Hello

    I would add a RadExpander Header in a DocumentHost a RadDocking. The pages would always be switched but Radexpander would be the top standard for all pages.

    I tried inserting a RadDocumentPane principal and the objects within it. The radExpander works but the screens give internal error when I drag.

    If RadPaneGroup had a header, I could insert the radExpander i, but i can´t.

    How can I fix this ?

    Follow my code

    <UserControl x:Class="RadDockingTemas.MainPage"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
        mc:Ignorable="d"
        d:DesignHeight="300" d:DesignWidth="400">
        
        <Grid x:Name="LayoutRoot" Background="White">
            <telerik:RadDocking>                        
                <telerik:RadSplitContainer>                
                    <telerik:RadPaneGroup x:Name="radPaneGroup1" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" 
                                                  Width="auto" Margin="0" Foreground="{x:Null}">
                        <telerik:RadPane x:Name="pnMenu" Width="52"  HorizontalAlignment="Stretch"
                                                 PaneHeaderVisibility="collapsed" IsPinned="True" CanUserClose="False">
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>                    
                </telerik:RadSplitContainer>            
                <telerik:RadDocking.DocumentHost>                
                    <telerik:RadSplitContainer BorderThickness="0" Margin="0,-6,0,0" Background="Transparent">
                        <telerik:RadPaneGroup BorderThickness="0">                    
                                <telerik:RadDocumentPane>
                                    <telerik:RadDocumentPane.HeaderTemplate>
                                        <DataTemplate>
                                        <telerik:RadExpander>
                                            <Rectangle Fill="Red" Height="100"/>
                                        </telerik:RadExpander>
                                    </DataTemplate>
                                    </telerik:RadDocumentPane.HeaderTemplate>                                
                                    <telerik:RadPaneGroup BorderThickness="0">                        
                                    <telerik:RadDocumentPane Title="teste"/>
                                    <telerik:RadDocumentPane Title="teste2"/>                                
                                </telerik:RadPaneGroup>
                            </telerik:RadDocumentPane>
                        </telerik:RadPaneGroup>                        
                    </telerik:RadSplitContainer>
                </telerik:RadDocking.DocumentHost>
     
            </telerik:RadDocking>
        </Grid>
    </UserControl>
    
     

  2. Masha
    Admin
    Masha avatar
    355 posts

    Posted 13 Mar 2013 Link to this post

    Hi Gilmar,

    I have a look at the xaml you sent to us and noticed that you inserted RadPaneGroup inside the RadPane. That is the reason you've got the exception. Please try the code snipped below:

    <telerik:RadDocking>                       
               <telerik:RadSplitContainer>               
                   <telerik:RadPaneGroup x:Name="radPaneGroup1" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
                                                 Width="auto" Margin="0" Foreground="{x:Null}">
                       <telerik:RadPane x:Name="pnMenu" Width="52"  HorizontalAlignment="Stretch"
                                                PaneHeaderVisibility="collapsed" IsPinned="True" CanUserClose="False">
                       </telerik:RadPane>
                   </telerik:RadPaneGroup>                   
               </telerik:RadSplitContainer>           
               <telerik:RadDocking.DocumentHost>               
                   <telerik:RadSplitContainer BorderThickness="0" Margin="0,-6,0,0" Background="Transparent">
                       <telerik:RadPaneGroup BorderThickness="0">
                           <telerik:RadDocumentPane>
                               <telerik:RadDocumentPane.HeaderTemplate>
                                   <DataTemplate>
                                       <telerik:RadExpander>
                                           <Rectangle Fill="Red" Height="100"/>
                                       </telerik:RadExpander>
                                   </DataTemplate>
                               </telerik:RadDocumentPane.HeaderTemplate>
                           </telerik:RadDocumentPane>
                           <telerik:RadDocumentPane Title="teste"/>
                           <telerik:RadDocumentPane Title="teste2"/>
                       </telerik:RadPaneGroup>
                       <telerik:RadPaneGroup BorderThickness="0">
                           <telerik:RadDocumentPane Title="teste"/>
                           <telerik:RadDocumentPane Title="teste2"/>
                       </telerik:RadPaneGroup>
     
                   </telerik:RadSplitContainer>
               </telerik:RadDocking.DocumentHost>
     
           </telerik:RadDocking>

    and let me know if it works for you.

    All the best,
    Maria
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. DevCraft banner
Back to Top