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

Simple sample does not work

7 Answers 126 Views
Docking
This is a migrated thread and some comments may be shown as answers.
andrew rekvils
Top achievements
Rank 1
andrew rekvils asked on 19 Mar 2009, 07:20 PM
I am trying to combine RadDocking and RadTreeView as it published in simple sample. My user control loads just fine if I have either RadDock or RadTreeView but not both. When I add radTreeView to RadPane I get an error that I can see from the frowser status bar that reads "... SysInvalidOperationException. InitializeError error #2101 in control 'Xaml1': Failed to initialize the application's root visual". Here is complete XAMl of my control.

Thank you,
Andrew

<

UserControl x:Class="SilverlightApplication1.Page"

 

xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

xmlns:telerikDocking="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking"

 

xmlns:telerikNavigation="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Navigation"

 

Width="900" Height="800">

 

 

<Grid x:Name="LayoutRoot" Background="Beige">

 

 

<telerikDocking:RadDocking x:Name="docking">

 

 

<telerikDocking:RadSplitContainer InitialPosition="DockedRight">

 

 

<telerikDocking:RadPaneGroup>

 

 

<telerikDocking:RadPane Header="Contacts">

 

 

<telerikNavigation:RadTreeView>

 

 

<telerikNavigation:RadTreeViewItem Header="Private">

 

 

<telerikNavigation:RadTreeViewItem Header="Peter" />

 

 

<telerikNavigation:RadTreeViewItem Header="Steve" />

 

 

</telerikNavigation:RadTreeViewItem>

 

 

<telerikNavigation:RadTreeViewItem Header="Work">

 

 

<telerikNavigation:RadTreeViewItem Header="Ivan" />

 

 

<telerikNavigation:RadTreeViewItem Header="Tony" />

 

 

</telerikNavigation:RadTreeViewItem>

 

 

</telerikNavigation:RadTreeView>

 

 

</telerikDocking:RadPane>

 

 

<telerikDocking:RadPane Header="Details">

 

 

</telerikDocking:RadPane>

 

 

</telerikDocking:RadPaneGroup>

 

 

</telerikDocking:RadSplitContainer>

 

 

</telerikDocking:RadDocking>

 

 

</Grid>

 

</

UserControl>

 

7 Answers, 1 is accepted

Sort by
0
Hristo
Telerik team
answered on 20 Mar 2009, 07:47 AM
Hello andrew rekvils,

Do you have reference to the following assemblies: Telerik.Windows.Controls, Telerik.Windows.Controls.Navigation and Telerik.Windows.Controls.Docking in your project?
They are need in order to run Docking example.

Kind regards,
Hristo
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.
0
andrew rekvils
Top achievements
Rank 1
answered on 20 Mar 2009, 12:04 PM
Hristo,

Yes, I have referenced to all three assemblies. As I wrote in my message if I have only one control (either RadDocking or RadTreeView) on my user control then each of them shows just fine which proves that I do have all required assembly references. The error happens only if I have both controls inside the same user control. I also noticed yesterday that if I place RadTreeView inside RadDocumentHost element RedTreeVew shows up, but not if it is inside RadPanel. XAML code attached to original message is exact content of my user control that does not work.

Thank you,
Andrew
0
Hristo
Telerik team
answered on 20 Mar 2009, 12:45 PM
Hello andrew rekvils,

Could you send us project demonstrating this error so we can investigate it further.
I was able to build your xaml without any modification and there is RadTreeView in the right pane.


Kind regards,
Hristo
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.
0
andrew rekvils
Top achievements
Rank 1
answered on 20 Mar 2009, 01:05 PM
How to attach zip file to this forum messages?
Thank you,
Andrew
0
Miroslav Nedyalkov
Telerik team
answered on 20 Mar 2009, 04:20 PM
Hi Andrew,

Attachments are not allowed in the forums due to security reasons. You should open a support ticket to be able to attach files.

Greetings,
Miroslav Nedyalkov
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Carlos Alberto
Top achievements
Rank 1
answered on 24 Mar 2009, 12:32 PM
I have the same problem


<

 

UserControl x:Class="BPM.Silver.Temp.PageTeste"

 

 

xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

 

 

xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

 

 

xmlns:designer="clr-namespace:BPM.Silver.Designer"

 

 

xmlns:radControls="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls"

 

 

xmlns:radNav="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Navigation"

 

 

xmlns:radDock="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking"

 

 

>

 

 

 

<Grid x:Name="LayoutRoot">

 

 

 

<Grid.RowDefinitions>

 

 

 

<RowDefinition Height="50"/>

 

 

 

<RowDefinition Height="*"/>

 

 

 

</Grid.RowDefinitions>

 

 

 

<Grid.ColumnDefinitions>

 

 

 

<ColumnDefinition Width="*" />

 

 

 

</Grid.ColumnDefinitions>

 

 

 

<Rectangle x:Name="temp" Grid.Row="0" Grid.Column="0" Fill="CadetBlue">

 

 

 

</Rectangle>

 

 

 

<radDock:RadDocking x:Name="dckMain" Grid.Row="1" Grid.Column="0" radControls:StyleManager.Theme="Vista">

 

 

 

<radNav:RadTabControl

 

 

Name="tabControl"

 

 

AllowDragOverTab="True" AllowDragReorder="False"

 

 

SelectedIndex="0"

 

 

>

 

 

 

<radNav:RadTabItem

 

 

Name="tabNew" Header="*"

 

 

HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"

 

 

IsTabStop="False"

 

 

>

 

 

 

</radNav:RadTabItem>

 

 

 

</radNav:RadTabControl>

 

 

 

<radDock:RadSplitContainer radDock:DockingPanel.InitialSize="150,150" MaxWidth="600"

 

 

Name="LeftContainer" InitialPosition="DockedLeft">

 

 

 

<radDock:RadPaneGroup x:Name="Group1">

 

 

 

<radDock:RadPane x:Name="panToolbar" Header="Toolbox">

 

 

 

<radDock:RadPane.Content>

 

 

 

<TextBlock Text="Test"></TextBlock>

 

 

 

</radDock:RadPane.Content>

 

 

 

</radDock:RadPane>

 

 

 

</radDock:RadPaneGroup>

 

 

 

</radDock:RadSplitContainer>

 

 

 

<radDock:RadSplitContainer radDock:DockingPanel.InitialSize="200,200"

 

 

x:Name="BottomContainer" InitialPosition="DockedBottom">

 

 

 

<radDock:RadPaneGroup x:Name="Group3">

 

 

 

<radDock:RadPane x:Name="Pane5" Header="Validao" IsPinned="False">

 

 

 

</radDock:RadPane>

 

 

 

<radDock:RadPane x:Name="Pane6" Header="Teste" IsPinned="False">

 

 

 

</radDock:RadPane>

 

 

 

</radDock:RadPaneGroup>

 

 

 

</radDock:RadSplitContainer>

 

 

 

</radDock:RadDocking>

 

 

 

</Grid>

 

</

 

UserControl>

 







 

using

 

System;

 

 

 

using

 

System.Collections.Generic;

 

 

 

using

 

System.Linq;

 

 

 

using

 

System.Net;

 

 

 

using

 

System.Windows;

 

 

 

using

 

System.Windows.Controls;

 

 

 

using

 

System.Windows.Documents;

 

 

 

using

 

System.Windows.Input;

 

 

 

using

 

System.Windows.Media;

 

 

 

using

 

System.Windows.Media.Animation;

 

 

 

using

 

System.Windows.Shapes;

 

 

 

namespace

 

BPM.Silver.Temp

 

{

 

public partial class PageTeste : UserControl

 

 

 

 

{

 

public PageTeste()

 

{

InitializeComponent();

}

}

}




0
Miroslav Nedyalkov
Telerik team
answered on 25 Mar 2009, 08:23 AM
Hi Carlos Alberto,

The code you sent doesn't present any errors. If it shows any errors to you, the problem might be in the references in your project. Also I see in your code something that is not correct - you have a TabControl just in the RadDocking and this is not correct. If you want to create something that looks like documents in visual studio you need to put your content in the DocumentHost of the RadDocking. Here is an example:
<radDock:RadDocking.DocumentHost> 
    <radDock:RadSplitContainer> 
        <radDock:RadPaneGroup> 
            <radDock:RadPane Header="pane 1" Content="some content" /> 
            <radDock:RadPane Header="pane 2" Content="some content" /> 
            <radDock:RadPane Header="pane 3" Content="some content" /> 
            <radDock:RadPane Header="pane 4" Content="some content" /> 
        </radDock:RadPaneGroup> 
    </radDock:RadSplitContainer> 
</radDock:RadDocking.DocumentHost> 

Please, let us know if have some troubles. If you still have problems, please open a support ticket, attach your project and write the error that you get.

Regards,
Miroslav Nedyalkov
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Docking
Asked by
andrew rekvils
Top achievements
Rank 1
Answers by
Hristo
Telerik team
andrew rekvils
Top achievements
Rank 1
Miroslav Nedyalkov
Telerik team
Carlos Alberto
Top achievements
Rank 1
Share this question
or