Error after Update to Windows 10

2 posts, 0 answers
  1. ITA
    ITA avatar
    383 posts
    Member since:
    Aug 2009

    Posted 11 Aug 2015 Link to this post

    Hi,

     i get an Error after updating to Win10.

    "ContextMenuTemplate should contain a RadContextMenu as root element."

    <UserControl x:Class="flexCRM_Adressen.Pages.Adresse"
                 xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                 xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
                 xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
                 mc:Ignorable="d" d:DesignHeight="800" d:DesignWidth="1200">
        <UserControl.Resources>
            <XmlDataProvider x:Key="Lang" Source="../lng/deutsch.xml" XPath="CrypTool"/>
            <Style TargetType="{x:Type telerik:PaneHeader}">
                <Setter Property="FontSize" Value="15" />
                <Setter Property="BorderThickness" Value="0,0,0,1"/>
                <Setter Property="BorderBrush" Value="#FFA0A0A0"/>
                <Setter Property="Background" Value="#e9e9e9" />
                <Setter Property="Height" Value="40" />
                <Setter Property="Padding" Value="5"/>
            </Style>
            <Style TargetType="{x:Type telerik:DocumentHost}">
                <Setter Property="FontSize" Value="15" />
                <Setter Property="BorderThickness" Value="0,0,0,1"/>
                <Setter Property="BorderBrush" Value="#FFA0A0A0"/>
                <Setter Property="Background" Value="#e9e9e9" />
                <Setter Property="Height" Value="40" />
                <Setter Property="Padding" Value="5"/>
            </Style>
            <Style TargetType="{x:Type telerik:GridViewColumn}" x:Key="VorgaengeRowStyle">
                 
            </Style>
             
            <DataTemplate x:Key="MyTemplate">
                <GroupBox Margin="10">
                    <GroupBox.HeaderTemplate>
                        <DataTemplate>
                            <Border Background="LawnGreen" CornerRadius="5,5,0,0">
                                <TextBlock Text="Kunde" Margin="5" Width="100"/>
                            </Border>
                        </DataTemplate>
                    </GroupBox.HeaderTemplate>
                    <Border Margin="10" ScrollViewer.VerticalScrollBarVisibility="Auto">
                        <Grid x:Name="ReadOnlyGrid">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"  />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                            </Grid.RowDefinitions>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="40" />
                                <ColumnDefinition Width="300" />
                                <ColumnDefinition Width="50" />
                                <ColumnDefinition Width="*" />
                            </Grid.ColumnDefinitions>
                             
                            <Image Grid.Column="0" Grid.Row="0" Source="/flexCRM_Adresssen;component/Style/Images/adressenr.png" Height="20" Margin="10,0,5,0"/>
                            <telerik:DataFormDataField Label="" DataMemberBinding="{Binding Identnummer, Mode=TwoWay}" Padding="0" Name="IdentnummerText" Grid.Row="0" Grid.Column="1" Height="Auto" FontSize="10" IsReadOnly="True" Margin="5"/>
                            <Image Grid.Column="0" Grid.Row="1" Source="/flexCRM_Adresssen;component/Style/Images/adresseninfo.png" Height="20" Margin="10,0,5,0"/>
                            <telerik:DataFormDataField Label="" DataMemberBinding="{Binding Name, Mode=TwoWay}" Padding="0" Name="NameText" Grid.Row="1" Grid.Column="1" Height="Auto" FontSize="10" HorizontalAlignment="Left" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch" FontWeight="SemiBold" Margin="5" MaxWidth="400"/>
                            <telerik:DataFormDataField Label=""  DataMemberBinding="{Binding Ans, Mode=TwoWay}" Padding="0" Name="AnschriftText" Grid.Row="2" Grid.Column="1" Height="Auto" FontSize="10" Margin="5" HorizontalAlignment="Left" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch" MaxWidth="400"/>
                            <telerik:DataFormDataField Label=""  DataMemberBinding="{Binding Str, Mode=TwoWay}" Padding="0" Name="StrasseText" Grid.Row="3" Grid.Column="1" Height="Auto" FontSize="10"  Margin="5" HorizontalAlignment="Left" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch" MaxWidth="400"/>
                            <StackPanel Grid.Row="4" Grid.Column="1" Orientation="Horizontal" VerticalAlignment="Center" HorizontalAlignment="Stretch">
                                <telerik:DataFormDataField Label=""  DataMemberBinding="{Binding Plz, Mode=TwoWay}" Width="70" Padding="0" Name="PlzText" Height="Auto" FontSize="10" HorizontalAlignment="Left" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch"  Margin="5"/>
                                <telerik:DataFormDataField Label="" DataMemberBinding="{Binding Nort, Mode=TwoWay}" Padding="0" Name="OrtText" Height="Auto" FontSize="10" HorizontalAlignment="Left" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch"  Margin="10,5,5,5" />
                            </StackPanel>
                            <telerik:DataFormDataField Label="" DataMemberBinding="{Binding Staat, Mode=TwoWay}" Padding="0" Name="StaatText" Grid.Row="5" Grid.Column="1" Height="Auto" FontSize="10" HorizontalAlignment="Left" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch" Margin="5" MaxWidth="400"/>
                             
                            <Image Grid.Column="2" Grid.Row="0" Source="/flexCRM_Adresssen;component/Style/Images/telefon.png" Height="20" />
                            <telerik:DataFormDataField DataMemberBinding="{Binding Tele, Mode=TwoWay}" Padding="0" Name="TelefonText" Grid.Row="0" Grid.Column="3" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" Margin="5" MaxWidth="400" />
                            <Image Grid.Column="2" Grid.Row="1" Source="/flexCRM_Adresssen;component/Style/Images/mobiltelefon.png" Height="20" />
                            <telerik:DataFormDataField DataMemberBinding="{Binding Mtele, Mode=TwoWay}" Padding="0" Name="MobilText" Grid.Row="1" Grid.Column="3" MaxWidth="400" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch" Margin="5" />
                            <Image Grid.Column="2" Grid.Row="2" Source="/flexCRM_Adresssen;component/Style/Images/email.png" Width="20" />
                            <telerik:DataFormDataField DataMemberBinding="{Binding Email, Mode=TwoWay}" Padding="0" Name="EmailText" Grid.Row="2" Grid.Column="3" MaxWidth="400" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch" Margin="5" />
                            <Image Grid.Column="2" Grid.Row="3" Source="/flexCRM_Adresssen;component/Style/Images/www.png" Width="20" />
                            <telerik:DataFormDataField DataMemberBinding="{Binding Urlt, Mode=TwoWay}" Padding="0" Name="UrlText" Grid.Row="3" Grid.Column="3" MaxWidth="400" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Left" VerticalContentAlignment="Stretch" Margin="5" />
                            <Button Grid.Column="2" Grid.Row="4" HorizontalContentAlignment="Left" Padding="0" Margin="5" Width="40" HorizontalAlignment="Left" BorderBrush="{x:Null}" BorderThickness="0">
                                <Image Source="/flexCRM_Adresssen;component/Style/Images/googlemaps.png" Stretch="Uniform" />
                            </Button>
                        </Grid>
                    </Border>
                </GroupBox>
            </DataTemplate>
     
            <DataTemplate x:Key="MyEditTemplate">
                <GroupBox Margin="10">
                    <GroupBox.HeaderTemplate>
                        <DataTemplate>
                            <Border Background="LawnGreen" CornerRadius="5,5,0,0">
                                <TextBlock Text="Kunde" Margin="5" Width="100"/>
                            </Border>
                        </DataTemplate>
                    </GroupBox.HeaderTemplate>
                    <Border Margin="10" ScrollViewer.VerticalScrollBarVisibility="Auto">
                        <Grid x:Name="ReadOnlyGrid">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"  />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="Auto" />
                            </Grid.RowDefinitions>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="40" />
                                <ColumnDefinition Width="320" />
                                <ColumnDefinition Width="50" />
                                <ColumnDefinition Width="320" />
                            </Grid.ColumnDefinitions>
     
                            <Image Grid.Column="0" Grid.Row="0" Source="/flexCRM_Adresssen;component/Style/Images/adressenr.png" Height="20" Margin="10,0,5,0"/>
                            <telerik:DataFormDataField Label="" DataMemberBinding="{Binding Identnummer, Mode=TwoWay}" Padding="0" Name="IdentnummerText" Grid.Row="0" Grid.Column="1" Height="Auto" FontSize="12" IsReadOnly="True" Margin="5"/>
                            <Image Grid.Column="0" Grid.Row="1" Source="/flexCRM_Adresssen;component/Style/Images/adresseninfo.png" Height="20" Margin="10,0,5,0"/>
                            <telerik:DataFormDataField Label="" DataMemberBinding="{Binding Name, Mode=TwoWay}" Padding="0" Name="NameText" Grid.Row="1" Grid.Column="1" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" FontWeight="SemiBold" Margin="5" />
                            <telerik:DataFormDataField Label=""  DataMemberBinding="{Binding Ans, Mode=TwoWay}" Padding="0" Name="AnschriftText" Grid.Row="2" Grid.Column="1" Height="Auto" FontSize="12" Margin="5" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"  />
                            <telerik:DataFormDataField Label=""  DataMemberBinding="{Binding Str, Mode=TwoWay}" Padding="0" Name="StrasseText" Grid.Row="3" Grid.Column="1" Height="Auto" FontSize="12"  Margin="5" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"  />
                            <StackPanel Grid.Row="4" Grid.Column="1" Orientation="Horizontal" VerticalAlignment="Center" HorizontalAlignment="Stretch">
                                <telerik:DataFormDataField Label=""  DataMemberBinding="{Binding Plz, Mode=TwoWay}" Width="70" Padding="0" Name="PlzText" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"  Margin="5"/>
                                <telerik:DataFormDataField Label="" DataMemberBinding="{Binding Nort, Mode=TwoWay}" Padding="0" Name="OrtText" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"  Margin="10,5,5,5" />
                            </StackPanel>
                            <telerik:DataFormDataField Label="" DataMemberBinding="{Binding Staat, Mode=TwoWay}" Padding="0" Name="StaatText" Grid.Row="5" Grid.Column="1" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"  Margin="5"/>
     
                            <Image Grid.Column="2" Grid.Row="0" Source="/flexCRM_Adresssen;component/Style/Images/telefon.png" Height="20" />
                            <telerik:DataFormDataField DataMemberBinding="{Binding Tele, Mode=TwoWay}" Padding="0" Name="TelefonText" Grid.Row="0" Grid.Column="3" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" Margin="5" Width="300"/>
                            <Image Grid.Column="2" Grid.Row="1" Source="/flexCRM_Adresssen;component/Style/Images/mobiltelefon.png" Height="20" />
                            <telerik:DataFormDataField DataMemberBinding="{Binding Mtele, Mode=TwoWay}" Padding="0" Name="MobilText" Grid.Row="1" Grid.Column="3" MaxWidth="350" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" Margin="5" Width="300"/>
                            <Image Grid.Column="2" Grid.Row="2" Source="/flexCRM_Adresssen;component/Style/Images/email.png" Width="20" />
                            <telerik:DataFormDataField DataMemberBinding="{Binding Email, Mode=TwoWay}" Padding="0" Name="EmailText" Grid.Row="2" Grid.Column="3" MaxWidth="350" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" Margin="5" Width="300"/>
                            <Image Grid.Column="2" Grid.Row="3" Source="/flexCRM_Adresssen;component/Style/Images/www.png" Width="20" />
                            <telerik:DataFormDataField DataMemberBinding="{Binding Urlt, Mode=TwoWay}" Padding="0" Name="UrlText" Grid.Row="3" Grid.Column="3" MaxWidth="350" Height="Auto" FontSize="12" HorizontalAlignment="Left" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" Margin="5" Width="300"/>
                            <Button Grid.Column="2" Grid.Row="4" HorizontalContentAlignment="Left" Padding="0" Margin="5" Width="40" HorizontalAlignment="Left" BorderBrush="{x:Null}" BorderThickness="0">
                                <Image Source="/flexCRM_Adresssen;component/Style/Images/googlemaps.png" Stretch="Uniform" />
                            </Button>
                        </Grid>
                    </Border>
                </GroupBox>
            </DataTemplate>
        </UserControl.Resources>
     
        <Grid x:Name="AdressenGrd">
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="*" />
                <ColumnDefinition Width="50" />
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
                <RowDefinition Height="*"/>
            </Grid.RowDefinitions>
     
            <Border Grid.Row="0" Grid.Column="1" Background="White" Margin="5,0,0,0">
                <Grid x:Name="AdressenHeaderGrid">
                    <Grid.RowDefinitions>
                        <RowDefinition Height="50" />
                        <RowDefinition Height="50" />
                        <RowDefinition Height="*" />
                    </Grid.RowDefinitions>
                    <telerik:RadButton VerticalAlignment="Center" BorderThickness="0" Height="Auto" HorizontalAlignment="Center" x:Name="LoadlayoutButton" Background="{x:Null}" Width="Auto" BorderBrush="Transparent"
                                               Margin="5" Grid.Row="0" Click="ButtonLoad_Click">
                        <StackPanel Orientation="Vertical">
                            <Image Width="35" Height="35" Source="/flexCRM_Adresssen;component/Style/Images/resetlayouttn.png"   />
                        </StackPanel>
                        <telerik:RadButton.Template>
                            <ControlTemplate TargetType="Button">
                                <ContentPresenter Content="{TemplateBinding Content}" Cursor="Hand" />
                            </ControlTemplate>
                        </telerik:RadButton.Template>
                    </telerik:RadButton>
                    <telerik:RadButton VerticalAlignment="Center" BorderThickness="0" Height="Auto" HorizontalAlignment="Center" x:Name="SavelayoutButton" Background="{x:Null}" Width="Auto" BorderBrush="Transparent"
                                               Margin="5" Grid.Row="1"  Click="ButtonSave_Click">
                        <StackPanel Orientation="Vertical">
                            <Image Width="35" Height="30" Source="Style/Images/savelayoutbtn.png"  />
                        </StackPanel>
                        <telerik:RadButton.Template>
                            <ControlTemplate TargetType="Button">
                                <ContentPresenter Content="{TemplateBinding Content}" Cursor="Hand" />
                            </ControlTemplate>
                        </telerik:RadButton.Template>
                    </telerik:RadButton>
                </Grid>
            </Border>
             
            <telerik:RadDocking x:Name="RadDocking1" Grid.Row="0" Grid.Column="0" Margin="0,0,10,0" BorderThickness="0" Padding="0">
                <telerik:RadDocking.DocumentHost >
                    <telerik:RadSplitContainer MinWidth="300" Height="490">
                        <telerik:RadPaneGroup telerik:RadDocking.SerializationTag="Group0">
                            <telerik:RadDocumentPane Header="Document 1" Title="Document 1" telerik:RadDocking.SerializationTag="pane0" CanUserClose="False" CanFloat="False" CanUserPin="False">
     
                                <telerik:RadDataForm x:Name="AdresseDataForm" ItemsSource="{Binding Adressen}" telerik:StyleManager.Theme="Windows8Touch" AutoGenerateFields="False"
                                                     ReadOnlyTemplate="{StaticResource MyTemplate}" EditTemplate="{StaticResource MyEditTemplate}" EditEnded="AdresseDataForm_OnEditEnded"
                                                     CommandButtonsVisibility="Cancel,Commit,Edit,Add,Delete"/>
                            </telerik:RadDocumentPane>
                        </telerik:RadPaneGroup>
                    </telerik:RadSplitContainer>
                </telerik:RadDocking.DocumentHost>
     
                <telerik:RadSplitContainer Orientation="Vertical" InitialPosition="DockedRight">
                    <telerik:RadPaneGroup  telerik:RadDocking.SerializationTag="Group1">
                        <telerik:RadPane Header="Vorgänge" Title="Vorgänge" CanUserClose="False" CanDockInDocumentHost="False" telerik:RadDocking.SerializationTag="pane1">
                            <Grid x:Name="VorgaengeGrid" Background="Transparent">
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="*" />
                                </Grid.RowDefinitions>
                                <wpfx:BusyIndicator Name="BusyBar" Margin="0" Grid.Row="0">
                                    <telerik:RadGridView telerik:StyleManager.Theme="Windows8" ShowGroupPanel="False" CanUserSortGroups="False" FontSize="14"
                                                         ShowColumnHeaders="False" BorderThickness="0" x:Name="VorgaengeRadGridViewRgv" SnapsToDevicePixels="True" IsFilteringAllowed="False"
                                                         CanUserDeleteRows="False" CanUserInsertRows="False" RowIndicatorVisibility="Collapsed" AutoGenerateColumns="False" BorderBrush="{x:Null}"
                                                         HorizontalGridLinesBrush="{x:Null}" VerticalGridLinesBrush="{x:Null}" FrozenColumnsSplitterVisibility="Collapsed" Margin="0,10,0,0" IsReadOnly="True"
                                                         SelectionMode="Single" FontFamily="Tahoma">
                                        <telerik:RadGridView.Columns>
                                            <telerik:GridViewDataColumn DataMemberBinding="{Binding Gruppe}" Width="*" IsVisible="False" Style="{StaticResource VorgaengeRowStyle}"   />
                                            <telerik:GridViewDataColumn DataMemberBinding="{Binding Type}" Width="auto"  />
                                            <telerik:GridViewDataColumn DataMemberBinding="{Binding Anzahl}" Width="*" />
                                        </telerik:RadGridView.Columns>
                                    </telerik:RadGridView>
                                </wpfx:BusyIndicator>
                            </Grid>
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>
     
                    <telerik:RadPaneGroup telerik:RadDocking.SerializationTag="Group2" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" >
                        <telerik:RadPane Header="Kalender" Title="Kalender" CanUserClose="False" CanDockInDocumentHost="False" telerik:RadDocking.SerializationTag="pane2">
                            <Frame x:Name="KalenderFrame" NavigationUIVisibility="Hidden" />
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>
     
                </telerik:RadSplitContainer>
     
                <telerik:RadSplitContainer Orientation="Horizontal" InitialPosition="DockedBottom">
                    <telerik:RadPaneGroup telerik:RadDocking.SerializationTag="Group4">
                        <telerik:RadPane Header="Pane Bottom 1" CanUserClose="False" CanDockInDocumentHost="False" telerik:RadDocking.SerializationTag="pane4" IsPinned="False">
     
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>
                </telerik:RadSplitContainer>
     
                <telerik:RadSplitContainer Orientation="Horizontal" InitialPosition="DockedBottom">
                    <telerik:RadPaneGroup  telerik:RadDocking.SerializationTag="Group3">
                        <telerik:RadPane Header="Umsatz" Title="Umsatz" CanUserClose="False" CanDockInDocumentHost="False" telerik:RadDocking.SerializationTag="pane3" Height="400">
                            <Frame x:Name="FinzanzenFrame" NavigationUIVisibility="Hidden" />
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>
                </telerik:RadSplitContainer>
            </telerik:RadDocking>
        </Grid>
    </UserControl>

    Where is the Problem?

     

    Thanks
    Best Regards
    Rene

  2. ITA
    ITA avatar
    383 posts
    Member since:
    Aug 2009

    Posted 11 Aug 2015 in reply to ITA Link to this post

    Problem solved!

    there must be a differenc between Windows7 + VS2012 and Windows10 + VS2013. I created the project new in VS2013 and no more error is shown.

    Thanks
  3. UI for WPF is Visual Studio 2017 Ready
Back to Top