none
不存在于“XML”命名空间,但是确显示正常,Why??? RRS feed

  • 问题

  • 根据“Telerik”官方文档做法,使用“RadDocking”控件。在VS2010的设计窗口下显示正常,但是去提示“元素”不属于命名空间的错误,这是怎么回事???Why???

    1、XAML代码

        <UserControl 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"
    x:Class="TelerikDockingTest.MainPage"
    Width="640" Height="480">

    <Grid x:Name="LayoutRoot" Background="White">
    <telerikDocking:RadDocking HasDocumentHost="True" HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
    <telerikDocking:RadSplitContainer>
    <telerikDocking:RadPaneGroup HorizontalAlignment="Stretch">
    <telerikDocking:RadPane Header="Pane 1"/>
    <telerikDocking:RadPane Header="Pane 2"/>
    </telerikDocking:RadPaneGroup>
    </telerikDocking:RadSplitContainer>
    </telerikDocking:RadDocking>
    </Grid>
    </UserControl>

     2、设计窗口正常,如下图:

         

    3、错误提示如下:

         错误 23 The tag 'RadSplitContainer' does not exist in XML namespace 'clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking'. C:\Users\Administrator\Desktop\Test\TelerikDockingTest\TelerikDockingTest\MainPage.xaml 9 5 TelerikDockingTest

    错误 24 The tag 'RadPaneGroup' does not exist in XML namespace 'clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking'. C:\Users\Administrator\Desktop\Test\TelerikDockingTest\TelerikDockingTest\MainPage.xaml 10 6 TelerikDockingTest

    错误 25 The tag 'RadPane' does not exist in XML namespace 'clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking'. C:\Users\Administrator\Desktop\Test\TelerikDockingTest\TelerikDockingTest\MainPage.xaml 11 7 TelerikDockingTest

    错误 26 The tag 'RadPane' does not exist in XML namespace 'clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking'. C:\Users\Administrator\Desktop\Test\TelerikDockingTest\TelerikDockingTest\MainPage.xaml 12 7 TelerikDockingTest

    错误 22 The tag 'RadDocking' does not exist in XML namespace 'clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Docking'. C:\Users\Administrator\Desktop\Test\TelerikDockingTest\TelerikDockingTest\MainPage.xaml 8 4 TelerikDockingTest

    问题:怎么会提示“RadSplitContainer”、“RadPaneGroup”、“RadPane”、“RadDocking”这些元素不存在???如果不存在,怎么设计模式下显示正常呢???


    Science and technology is my lover.

    2012年5月22日 8:02

答案