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

RadDocumentPane - HeaderTemplate not working

3 Answers 149 Views
Docking
This is a migrated thread and some comments may be shown as answers.
Brian
Top achievements
Rank 1
Brian asked on 07 Jul 2011, 05:58 PM

I am trying to set up a header template on a RadDocumentPane but nothing is showing up.  Below is my code.  Why is this not working?
Tks.

<DataTemplate x:Key="GraphViewPaneHeaderTemplate">
            <TextBlock Text="Graph Views"  />
        </DataTemplate>

<telerik:RadPaneGroup telerik:ProportionalStackPanel.RelativeSize="200, 100">
                    <telerik:RadDocumentPane HeaderTemplate="{StaticResource GraphViewPaneHeaderTemplate}" CanUserClose="False" CanUserPin="False" ContextMenuTemplate="{x:Null}" >
                        <Controls:GraphViewControl DataContext="{Binding SelectedGraphViewVM}" HorizontalAlignment="Stretch" VerticalContentAlignment="Stretch" />
                    </telerik:RadDocumentPane>
                </telerik:RadPaneGroup>

3 Answers, 1 is accepted

Sort by
0
Brian
Top achievements
Rank 1
answered on 12 Jul 2011, 02:55 PM
Anyone?  Bueller?
0
Pana
Telerik team
answered on 13 Jul 2011, 07:19 AM
Hello Brian,

Please check the following XAML:

<telerik:RadDocking>
    <telerik:RadSplitContainer>
        <telerik:RadPaneGroup>
            <telerik:RadPane>
                <telerik:RadPane.HeaderTemplate>
                    <DataTemplate>
                        <Border Background="Green">
                            <TextBlock Text="Test" />
                        </Border>
                    </DataTemplate>
                </telerik:RadPane.HeaderTemplate>
            </telerik:RadPane>
            <telerik:RadPane IsSelected="True">
                <telerik:RadPane.TitleTemplate>
                    <DataTemplate>
                        <Border Background="Red">
                            <TextBlock Text="Header" />
                        </Border>
                    </DataTemplate>
                </telerik:RadPane.TitleTemplate>
            </telerik:RadPane>
        </telerik:RadPaneGroup>
    </telerik:RadSplitContainer>
</telerik:RadDocking>

The Header template is presented in the RadPaneGroup's "Tab" items while the TitleTemplate is used in the RadPaneGroup's top PaneHeader control - the one that has menu and [x] button. I guess you needed the Title template instead of the Header.

Best wishes,
Pana
the Telerik team

Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

0
Brian
Top achievements
Rank 1
answered on 13 Jul 2011, 03:14 PM
Yep, that was it.

Thanks!
Tags
Docking
Asked by
Brian
Top achievements
Rank 1
Answers by
Brian
Top achievements
Rank 1
Pana
Telerik team
Share this question
or