Infromations not displaying

2 posts, 0 answers
  1. Christie Admin
    Christie Admin avatar
    239 posts
    Member since:
    Aug 2013

    Posted 07 Jan 2014 Link to this post

    Hi,

    in my project I have multiple usercontrols using the ScheduleView control. For each usercontrol I use the Office2013 theme and all of my usercontrol refuse to display the date in columns headers,

    Here is on of my user control:

    <UserControl x:Class="AppointmentControls.CreateSchedule.CreateSchedule"
                 xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                 xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                 xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"             
                 xmlns:AppCtrl="clr-namespace:AppointmentControls"
                 xmlns:ScheduleCreation="clr-namespace:AppointmentControls.CreateSchedule"
                 xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
                 xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
                 mc:Ignorable="d"
                 d:DesignHeight="300" d:DesignWidth="300" x:Name="Me">

        <UserControl.Resources>
            <ResourceDictionary>
                <ResourceDictionary.MergedDictionaries>
                    <ResourceDictionary Source="/Telerik.Windows.Themes.Office2013;component/Themes/System.Windows.xaml"/>
                    <ResourceDictionary Source="/Telerik.Windows.Themes.Office2013;component/Themes/Telerik.Windows.Controls.xaml"/>
                    <ResourceDictionary Source="/Telerik.Windows.Themes.Office2013;component/Themes/Telerik.Windows.Controls.Input.xaml"/>
                    <ResourceDictionary Source="/Telerik.Windows.Themes.Office2013;component/Themes/Telerik.Windows.Controls.Navigation.xaml"/>
                    <ResourceDictionary Source="/Telerik.Windows.Themes.Office2013;component/Themes/Telerik.Windows.Controls.ScheduleView.xaml"/>
                </ResourceDictionary.MergedDictionaries>
            </ResourceDictionary>
        </UserControl.Resources>

        <Grid x:Name="Root">
            <telerik:RadScheduleView x:Name="Control" IsInlineEditingEnabled="False" FirstDayOfWeek="Monday" ActiveViewDefinitionIndex="0" NavigationHeaderVisibility="Collapsed" MinTimeRulerExtent="200" MaxTimeRulerExtent="5000"
                                     AppointmentSelectionChanged="Control_AppointmentSelectionChanged" AppointmentDeleted="Control_AppointmentDeleted" AppointmentCreated="Control_AppointmentCreated" AppointmentEdited="Control_AppointmentEdited">
                <telerik:RadScheduleView.ViewDefinitions>
                    <telerik:WeekViewDefinition x:Name="View" MajorTickLength="1h" FirstDayOfWeek="Monday" MinorTickLength="1h" TimerulerMajorTickStringFormat="{}{0:H }:{0:mm} " TimerulerMinorTickStringFormat=":{0:mm} " GroupHeaderDateStringFormat="{}{0:dddd}" />
                </telerik:RadScheduleView.ViewDefinitions>
            </telerik:RadScheduleView>
        </Grid>
    </UserControl>

    I have the following warning message in my VS2013:

    System.Windows.ResourceDictionary Warning: 9 : Resource not found; ResourceKey='Telerik.Windows.Controls.InternalResourceKey'; ResourceKey.HashCode='16'; ResourceKey.Type='Telerik.Windows.Controls.InternalResourceKey'

  2. Kalin
    Admin
    Kalin avatar
    1209 posts

    Posted 10 Jan 2014 Link to this post

    Hello Alain,

    The issue is caused because the ResourceDictionaries are merged on UserControl level and they should be merged in the App.xaml - on application level. This is so because the Theme contains dynamic resources which should be loaded at start up of the Application and this is causing the missing resource exception. So you just need to move the MergedDictionaries into App.xaml and the text will appear.

    Hope this helps.

    Regards,
    Kalin
    Telerik
    TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
    Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
    Sign up for Free application insights >>
  3. UI for WPF is Visual Studio 2017 Ready
Back to Top