Telerik Forums
UI for Silverlight Forum
2 answers
72 views
We've recently upgraded the telerik components in our solution and the solution itself to Silverlight 5 and version 2014.3.1021.1050 of the controls.

We use a custom user control that is made up of a date control and a radTimePicker control. The radTimePicker control has a custom style applied to it to add a clock icon into the text box.
We noticed that after the upgrade the initial value was no longer being set.
The solution is MVVM and looking more into the binding it looks like the binding in the style especially this bit SelectedItem="{Binding SelectedTime, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" is setting the value to null after the binding where I'm setting a value.

In order to test this and work out what's going on (and rule out anything we've done) I've created a new project with a user control with just the radTimePicker in it and obtained the default style from blend for the control and set that.

Without the style applied the control works ok.
With the style applied the control doesn't load my initial value but the time picker works at setting a new value
With the above line from the style removed, the initial value is set but the time picker no longer works

(by time picker I mean the drop down bit)

The code for the TimerPicker.xaml user control is

<UserControl x:Class="RadTimePickerTest.TimerPicker"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" xmlns:System="clr-namespace:System;assembly=mscorlib" xmlns:Calendar="clr-namespace:Telerik.Windows.Controls.Calendar;assembly=Telerik.Windows.Controls.Input" xmlns:Chromes="clr-namespace:Telerik.Windows.Controls.Chromes;assembly=Telerik.Windows.Controls"
         
    
    mc:Ignorable="d"
    d:DesignHeight="300" d:DesignWidth="400">

    <UserControl.Resources>
        <SolidColorBrush x:Key="PickerForeground_Normal" Color="#FF000000"/>
        <SolidColorBrush x:Key="CalendarOuterBorder" Color="#FF848484"/>
        <SolidColorBrush x:Key="CalendarViewBackground" Color="#FFFFFFFF"/>
        <Thickness x:Key="CalendarViewBorderThickness">1</Thickness>
        <Thickness x:Key="CalendarViewHeaderPadding">3</Thickness>
        <SolidColorBrush x:Key="CalendarSubHeaderOuterBorder" Color="#FF848484"/>
        <LinearGradientBrush x:Key="CalendarSubHeaderBackground" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="White" Offset="0"/>
            <GradientStop Color="#FFCDCDCD" Offset="1"/>
            <GradientStop Color="#FFCECECE" Offset="0.42"/>
            <GradientStop Color="#FFAFAFAF" Offset="0.43"/>
        </LinearGradientBrush>
        <SolidColorBrush x:Key="CalendarSubHeaderInnerBorder" Color="#FFFFFFFF"/>
        <Thickness x:Key="CalendarViewHeaderMargin">0 0 0 0</Thickness>
        <SolidColorBrush x:Key="CalendarWeekHeaderVerticalOuterBorder" Color="#FF848484"/>
        <Thickness x:Key="CalendarWeekHeaderVerticalOuterBorderThickness">1 0 1 1</Thickness>
        <Thickness x:Key="CalendarWeekHeaderVerticalOuterBorderMargin">0 0 -1 0</Thickness>
        <telerik:InvertedBooleanToVisibilityConverter x:Key="InvertedBooleanToVisibilityConverterInstance"/>
        <System:Int32 x:Key="CalendarWeekHeaderVerticalOuterBorderZIndex">0</System:Int32>
        <SolidColorBrush x:Key="CalendarWeekHeaderHorizontalOuterBorder" Color="#FF848484"/>
        <Thickness x:Key="CalendarWeekHeaderHorizontalOuterBorderThickness">1 0 1 1</Thickness>
        <Thickness x:Key="CalendarWeekHeaderHorizontalOuterBorderMargin">0 0 0 0</Thickness>
        <System:Int32 x:Key="CalendarWeekHeaderHorizontalOuterBorderZIndex">0</System:Int32>
        <SolidColorBrush x:Key="CalendarWeekHeaderVerticalInnerBorder" Color="#FFFFFFFF"/>
        <Thickness x:Key="CalendarWeekHeaderVerticalInnerBorderThickness">1</Thickness>
        <Thickness x:Key="CalendarWeekHeaderVerticalInnerBorderMargin">1 1 0 1</Thickness>
        <System:Int32 x:Key="CalendarWeekHeaderVerticalInnerBorderZIndex">0</System:Int32>
        <SolidColorBrush x:Key="CalendarWeekHeaderHorizontalInnerBorder" Color="#FFFFFFFF"/>
        <Thickness x:Key="CalendarWeekHeaderHorizontalInnerBorderThickness">1</Thickness>
        <Thickness x:Key="CalendarWeekHeaderHorizontalInnerBorderMargin">1 0 1 1</Thickness>
        <System:Int32 x:Key="CalendarWeekHeaderHorizontalInnerBorderZIndex">0</System:Int32>
        <SolidColorBrush x:Key="CalendarWeekHeaderVerticalBackground" Color="#FFE4E4E4"/>
        <Thickness x:Key="CalendarWeekHeaderVerticalBackgroundMargin">2 2 1 2</Thickness>
        <System:Int32 x:Key="CalendarWeekHeaderVerticalBackgroundZIndex">0</System:Int32>
        <SolidColorBrush x:Key="CalendarWeekHeaderHorizontalBackground" Color="#FFE4E4E4"/>
        <Thickness x:Key="CalendarWeekHeaderHorizontalBackgroundMargin">2 1 2 2</Thickness>
        <System:Int32 x:Key="CalendarWeekHeaderHorizontalBackgroundZIndex">0</System:Int32>
        <Thickness x:Key="CalendarItemsMargin">1 0 1 1</Thickness>
        <Thickness x:Key="CalendarViewMargin">-1 -1 0 0</Thickness>
        <Style x:Key="MonthViewStyle" TargetType="Calendar:CalendarView">
            <Setter Property="HorizontalContentAlignment" Value="Center"/>
            <Setter Property="VerticalContentAlignment" Value="Center"/>
            <Setter Property="BorderBrush" Value="{StaticResource CalendarOuterBorder}"/>
            <Setter Property="Background" Value="{StaticResource CalendarViewBackground}"/>
            <Setter Property="BorderThickness" Value="{StaticResource CalendarViewBorderThickness}"/>
            <Setter Property="Padding" Value="{StaticResource CalendarViewHeaderPadding}"/>
            <Setter Property="IsTabStop" Value="False"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Calendar:CalendarView">
                        <Grid Margin="{StaticResource CalendarViewMargin}">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="*"/>
                            </Grid.RowDefinitions>
                            <Border x:Name="BackgroundVisual" Background="{TemplateBinding Background}" Grid.RowSpan="2"/>
                            <Border x:Name="Header" BorderBrush="{StaticResource CalendarSubHeaderOuterBorder}" BorderThickness="{TemplateBinding BorderThickness}" Background="{StaticResource CalendarSubHeaderBackground}" Margin="{StaticResource CalendarViewHeaderMargin}" Visibility="{TemplateBinding HeaderVisibility}">
                                <Border BorderBrush="{StaticResource CalendarSubHeaderInnerBorder}" BorderThickness="{TemplateBinding BorderThickness}">
                                    <ContentPresenter ContentTemplate="{TemplateBinding HeaderTemplate}" Content="{TemplateBinding Header}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
                                </Border>
                            </Border>
                            <Grid x:Name="WeekHeaders" Grid.Row="1">
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="7*"/>
                                </Grid.ColumnDefinitions>
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="*"/>
                                    <RowDefinition Height="6*"/>
                                </Grid.RowDefinitions>
                                <Border x:Name="VerticalOuterBorder" BorderBrush="{StaticResource CalendarWeekHeaderVerticalOuterBorder}" BorderThickness="{StaticResource CalendarWeekHeaderVerticalOuterBorderThickness}" Margin="{StaticResource CalendarWeekHeaderVerticalOuterBorderMargin}" Grid.RowSpan="2" Visibility="{Binding HideColumn, Converter={StaticResource InvertedBooleanToVisibilityConverterInstance}, RelativeSource={RelativeSource TemplatedParent}}" Canvas.ZIndex="{StaticResource CalendarWeekHeaderVerticalOuterBorderZIndex}"/>
                                <Border x:Name="HorizontalOuterBorder" BorderBrush="{StaticResource CalendarWeekHeaderHorizontalOuterBorder}" BorderThickness="{StaticResource CalendarWeekHeaderHorizontalOuterBorderThickness}" Grid.ColumnSpan="2" Margin="{StaticResource CalendarWeekHeaderHorizontalOuterBorderMargin}" Visibility="{Binding HideRow, Converter={StaticResource InvertedBooleanToVisibilityConverterInstance}, RelativeSource={RelativeSource TemplatedParent}}" Canvas.ZIndex="{StaticResource CalendarWeekHeaderHorizontalOuterBorderZIndex}"/>
                                <Border x:Name="VerticalInnerBorder" BorderBrush="{StaticResource CalendarWeekHeaderVerticalInnerBorder}" BorderThickness="{StaticResource CalendarWeekHeaderVerticalInnerBorderThickness}" Margin="{StaticResource CalendarWeekHeaderVerticalInnerBorderMargin}" Grid.RowSpan="2" Visibility="{Binding HideColumn, Converter={StaticResource InvertedBooleanToVisibilityConverterInstance}, RelativeSource={RelativeSource TemplatedParent}}" Canvas.ZIndex="{StaticResource CalendarWeekHeaderVerticalInnerBorderZIndex}"/>
                                <Border x:Name="HorizontalInnerBorder" BorderBrush="{StaticResource CalendarWeekHeaderHorizontalInnerBorder}" BorderThickness="{StaticResource CalendarWeekHeaderHorizontalInnerBorderThickness}" Grid.ColumnSpan="2" Margin="{StaticResource CalendarWeekHeaderHorizontalInnerBorderMargin}" Visibility="{Binding HideRow, Converter={StaticResource InvertedBooleanToVisibilityConverterInstance}, RelativeSource={RelativeSource TemplatedParent}}" Canvas.ZIndex="{StaticResource CalendarWeekHeaderHorizontalInnerBorderZIndex}"/>
                                <Rectangle x:Name="VerticalBackground" Fill="{StaticResource CalendarWeekHeaderVerticalBackground}" Margin="{StaticResource CalendarWeekHeaderVerticalBackgroundMargin}" Grid.RowSpan="2" Visibility="{Binding HideColumn, Converter={StaticResource InvertedBooleanToVisibilityConverterInstance}, RelativeSource={RelativeSource TemplatedParent}}" Canvas.ZIndex="{StaticResource CalendarWeekHeaderVerticalBackgroundZIndex}"/>
                                <Rectangle x:Name="HorizontalBackground" Grid.ColumnSpan="2" Fill="{StaticResource CalendarWeekHeaderHorizontalBackground}" Margin="{StaticResource CalendarWeekHeaderHorizontalBackgroundMargin}" Visibility="{Binding HideRow, Converter={StaticResource InvertedBooleanToVisibilityConverterInstance}, RelativeSource={RelativeSource TemplatedParent}}" Canvas.ZIndex="{StaticResource CalendarWeekHeaderHorizontalBackgroundZIndex}"/>
                            </Grid>
                            <ItemsPresenter Margin="{StaticResource CalendarItemsMargin}" Grid.Row="1"/>
                            <Border x:Name="BorderBrush" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Grid.RowSpan="2"/>
                            <Rectangle x:Name="MinDesiredSize" Height="155" Grid.Row="1" Width="240"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="Margin" Value="0"/>
        </Style>
        <Style x:Key="CalendarViewStyle" TargetType="Calendar:CalendarView">
            <Setter Property="HorizontalContentAlignment" Value="Center"/>
            <Setter Property="VerticalContentAlignment" Value="Center"/>
            <Setter Property="BorderBrush" Value="{StaticResource CalendarOuterBorder}"/>
            <Setter Property="Background" Value="{StaticResource CalendarViewBackground}"/>
            <Setter Property="BorderThickness" Value="{StaticResource CalendarViewBorderThickness}"/>
            <Setter Property="Padding" Value="{StaticResource CalendarViewHeaderPadding}"/>
            <Setter Property="IsTabStop" Value="False"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Calendar:CalendarView">
                        <Grid Margin="{StaticResource CalendarViewMargin}">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="*"/>
                            </Grid.RowDefinitions>
                            <Border x:Name="BackgroundVisual" Background="{TemplateBinding Background}" Grid.RowSpan="2"/>
                            <Border x:Name="Header" BorderBrush="{StaticResource CalendarSubHeaderOuterBorder}" BorderThickness="{TemplateBinding BorderThickness}" Background="{StaticResource CalendarSubHeaderBackground}" Margin="{StaticResource CalendarViewHeaderMargin}" Visibility="{TemplateBinding HeaderVisibility}">
                                <Border BorderBrush="{StaticResource CalendarSubHeaderInnerBorder}" BorderThickness="{TemplateBinding BorderThickness}">
                                    <ContentPresenter ContentTemplate="{TemplateBinding HeaderTemplate}" Content="{TemplateBinding Header}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
                                </Border>
                            </Border>
                            <ItemsPresenter Margin="{StaticResource CalendarItemsMargin}" Grid.Row="1"/>
                            <Border x:Name="BorderBrush" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Grid.RowSpan="2"/>
                            <Rectangle x:Name="MinDesiredSize" Height="155" Grid.Row="1" Width="240"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="Margin" Value="0"/>
        </Style>
        <CornerRadius x:Key="SplitButton_SpanCornerRadius">1</CornerRadius>
        <Thickness x:Key="CalendarButtonButtonChromeMargin">2</Thickness>
        <telerik:Office_BlackTheme x:Key="Theme"/>
        <LinearGradientBrush x:Key="ControlOuterBorder_Pressed" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="#FF282828"/>
            <GradientStop Color="#FF5F5F5F" Offset="1"/>
        </LinearGradientBrush>
        <Thickness x:Key="CalendarButtonTodayVisualMargin">1</Thickness>
        <Style x:Key="CalendarButtonStyle" TargetType="Calendar:CalendarButton">
            <Setter Property="Padding" Value="0"/>
            <Setter Property="HorizontalContentAlignment" Value="Center"/>
            <Setter Property="VerticalContentAlignment" Value="Center"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Calendar:CalendarButton">
                        <Grid x:Name="LayoutRoot" Background="Transparent">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="LayoutRoot">
                                                <DiscreteDoubleKeyFrame KeyTime="0" Value="0.5"/>
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Normal">
                                        <Storyboard>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="LayoutRoot">
                                                <DiscreteDoubleKeyFrame KeyTime="0" Value="1"/>
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="MouseOver"/>
                                    <VisualState x:Name="IsInAnotherView"/>
                                    <VisualState x:Name="IsNotFromCurrentView">
                                        <Storyboard>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="Content">
                                                <DiscreteDoubleKeyFrame KeyTime="0" Value="0.5"/>
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="ButtonType">
                                    <VisualState x:Name="Year"/>
                                    <VisualState x:Name="Decade"/>
                                    <VisualState x:Name="Date"/>
                                    <VisualState x:Name="WeekName">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="SelectionChrome">
                                                <DiscreteObjectKeyFrame KeyTime="00:00:00">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Collapsed</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="WeekNumber">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="SelectionChrome">
                                                <DiscreteObjectKeyFrame KeyTime="00:00:00">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Collapsed</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="TodayDate">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="TodayVisual">
                                                <DiscreteObjectKeyFrame KeyTime="00:00:00">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Visible</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Month"/>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Unfocused"/>
                                    <VisualState x:Name="Focused">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderThickness" Storyboard.TargetName="SelectionChrome">
                                                <DiscreteObjectKeyFrame KeyTime="0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Thickness>1</Thickness>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="SelectionStates">
                                    <VisualState x:Name="Unselected"/>
                                    <VisualState x:Name="Selected"/>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}"/>
                            <Chromes:ButtonChrome x:Name="SelectionChrome" CornerRadius="{StaticResource SplitButton_SpanCornerRadius}" Margin="{StaticResource CalendarButtonButtonChromeMargin}" RenderNormal="False" RenderSelected="{TemplateBinding IsSelected}" RenderFocused="{TemplateBinding IsFocused}" RenderHighlighted="{TemplateBinding IsMouseOver}" telerik:StyleManager.Theme="{StaticResource Theme}"/>
                            <Border x:Name="TodayVisual" BorderBrush="{StaticResource ControlOuterBorder_Pressed}" BorderThickness="1" CornerRadius="2" Margin="{StaticResource CalendarButtonTodayVisualMargin}" Visibility="Collapsed"/>
                            <ContentPresenter x:Name="Content" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <SolidColorBrush x:Key="PanelBackground" Color="#FFFFFFFF"/>
        <Thickness x:Key="CalendarHeaderPadding">0</Thickness>
        <Thickness x:Key="CalendarTransitionPanelMargin">0 0 0 0</Thickness>
        <SolidColorBrush x:Key="CalendarInnerBorder" Color="Transparent"/>
        <CornerRadius x:Key="CalendarInnerBorderCornerRadius">0</CornerRadius>
        <CornerRadius x:Key="CalendarOuterBorderCornerRadius">0</CornerRadius>
        <SolidColorBrush x:Key="HeaderOuterBorder" Color="#FF000000"/>
        <Thickness x:Key="CalendarHeaderBorderThickness">1</Thickness>
        <LinearGradientBrush x:Key="HeaderBackground" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="#FF5B5B5B" Offset="1"/>
            <GradientStop Color="#FF868686"/>
            <GradientStop Color="#FF4F4F4F" Offset="0.42"/>
            <GradientStop Color="#FF0E0E0E" Offset="0.43"/>
        </LinearGradientBrush>
        <SolidColorBrush x:Key="HeaderInnerBorder" Color="#FFB5B5B5"/>
        <SolidColorBrush x:Key="HeaderButtonOuterBorder_Normal" Color="#FF848484"/>
        <SolidColorBrush x:Key="HeaderButtonBackground_Normal" Color="Transparent"/>
        <SolidColorBrush x:Key="HeaderButtonInnerBorder_Normal" Color="Transparent"/>
        <SolidColorBrush x:Key="HeaderButtonOuterBorder_MouseOver" Color="#FFFFC92B"/>
        <SolidColorBrush x:Key="HeaderButtonInnerBorder_MouseOver" Color="#FFFFFFFF"/>
        <LinearGradientBrush x:Key="HeaderButtonBackground_MouseOver" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="#FFFFFBA3" Offset="1"/>
            <GradientStop Color="#FFFFFBDA" Offset="0"/>
            <GradientStop Color="#FFFFD25A" Offset="0.43"/>
            <GradientStop Color="#FFFEEBAE" Offset="0.42"/>
        </LinearGradientBrush>
        <LinearGradientBrush x:Key="HeaderButtonOuterBorder_Pressed" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="#FF5F5F5F" Offset="1"/>
            <GradientStop Color="#FF282828"/>
        </LinearGradientBrush>
        <LinearGradientBrush x:Key="HeaderButtonInnerBorder_Pressed" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="#FFB69A78"/>
            <GradientStop Color="#FFFFE17A" Offset="0.126"/>
        </LinearGradientBrush>
        <LinearGradientBrush x:Key="HeaderButtonBackground_Pressed" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="#FFFFD74E" Offset="0.996"/>
            <GradientStop Color="#FFFFDCAB" Offset="0.17"/>
            <GradientStop Color="#FFFE9227" Offset="0.57"/>
            <GradientStop Color="#FFFFD18F" Offset="0.56"/>
            <GradientStop Color="#FFFFBA74" Offset="0"/>
        </LinearGradientBrush>
        <Style x:Key="HeaderButtonChrome" TargetType="Chromes:ButtonChrome">
            <Setter Property="BorderThickness" Value="1"/>
            <Setter Property="BorderBrush" Value="{StaticResource HeaderButtonOuterBorder_Normal}"/>
            <Setter Property="Background" Value="{StaticResource HeaderButtonBackground_Normal}"/>
            <Setter Property="CornerRadius" Value="{StaticResource SplitButton_SpanCornerRadius}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Chromes:ButtonChrome">
                        <Grid>
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="MouseOver">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="OuterBorder">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonOuterBorder_MouseOver}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="InnerBorder">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonInnerBorder_MouseOver}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="OuterBorder">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonBackground_MouseOver}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="OuterBorder">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonOuterBorder_Pressed}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="InnerBorder">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonInnerBorder_Pressed}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="OuterBorder">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonBackground_Pressed}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Border x:Name="OuterBorder" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="{TemplateBinding CornerRadius}">
                                <Border x:Name="InnerBorder" BorderBrush="{StaticResource HeaderButtonInnerBorder_Normal}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="{TemplateBinding InnerCornerRadius}"/>
                            </Border>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <SolidColorBrush x:Key="HeaderButtonIconBackground_Normal" Color="#FF000000"/>
        <SolidColorBrush x:Key="HeaderButtonIconForeground_Normal" Color="#FFFFFFFF"/>
        <SolidColorBrush x:Key="HeaderButtonIconBackground_Disabled" Color="#88000000"/>
        <SolidColorBrush x:Key="HeaderButtonIconForeground_Disabled" Color="#88FFFFFF"/>
        <SolidColorBrush x:Key="HeaderButtonIconBackground_MouseOver" Color="#FFFFFFFF"/>
        <SolidColorBrush x:Key="HeaderButtonIconForeground_MouseOver" Color="#FF000000"/>
        <SolidColorBrush x:Key="HeaderButtonIconBackground_Pressed" Color="#FFFFFFFF"/>
        <SolidColorBrush x:Key="HeaderButtonIconForeground_Pressed" Color="#FF000000"/>
        <Style x:Key="MoveLeftButtonStyle" TargetType="RepeatButton">
            <Setter Property="Width" Value="22"/>
            <Setter Property="Height" Value="22"/>
            <Setter Property="Margin" Value="3"/>
            <Setter Property="IsTabStop" Value="False"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="RepeatButton">
                        <Grid Background="Transparent">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="BackgroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconBackground_Disabled}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ForegroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconForeground_Disabled}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="MouseOver">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="BackgroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconBackground_MouseOver}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ForegroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconForeground_MouseOver}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="BackgroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconBackground_Pressed}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ForegroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconForeground_Pressed}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Chromes:ButtonChrome CornerRadius="{StaticResource SplitButton_SpanCornerRadius}" RenderMouseOver="{TemplateBinding IsMouseOver}" RenderPressed="{TemplateBinding IsPressed}" RenderFocused="{TemplateBinding IsFocused}" Style="{StaticResource HeaderButtonChrome}"/>
                            <Path x:Name="BackgroundIcon" Data="M4,0 L4,7 3,7 3,6 2,6 2,5 1,5 1,4 0,4 0,3 1,3 1,2 2,2 2,1 3,1 3,0 z" Fill="{StaticResource HeaderButtonIconBackground_Normal}" Height="7" Margin="0 2 0 0" Width="4"/>
                            <Path x:Name="ForegroundIcon" Data="M4,0 L4,7 3,7 3,6 2,6 2,5 1,5 1,4 0,4 0,3 1,3 1,2 2,2 2,1 3,1 3,0 z" Fill="{StaticResource HeaderButtonIconForeground_Normal}" Height="7" Margin="0 1 0 1" Width="4"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <SolidColorBrush x:Key="HeaderTextBackground" Color="#FF000000"/>
        <FontWeight x:Key="HeaderTextFontWeight">Bold</FontWeight>
        <SolidColorBrush x:Key="HeaderTextForeground" Color="#FFFFFFFF"/>
        <TextDecorationCollection x:Key="HeaderButtonTextDecoration">Underline</TextDecorationCollection>
        <Style x:Key="CalendarHeaderButton" TargetType="Button">
            <Setter Property="Height" Value="22"/>
            <Setter Property="Margin" Value="3"/>
            <Setter Property="Cursor" Value="Hand"/>
            <Setter Property="IsTabStop" Value="False"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Grid x:Name="LayoutRoot">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="LayoutRoot">
                                                <DiscreteDoubleKeyFrame KeyTime="0" Value="0.75"/>
                                            </DoubleAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="MouseOver">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="TextDecorations" Storyboard.TargetName="ForegroundText">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonTextDecoration}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="TextDecorations" Storyboard.TargetName="BackgroundText">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonTextDecoration}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Focused">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="TextDecorations" Storyboard.TargetName="ForegroundText">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonTextDecoration}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="TextDecorations" Storyboard.TargetName="BackgroundText">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonTextDecoration}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="TextDecorations" Storyboard.TargetName="ForegroundText">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonTextDecoration}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="TextDecorations" Storyboard.TargetName="BackgroundText">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonTextDecoration}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <TextBlock x:Name="BackgroundText" Foreground="{StaticResource HeaderTextBackground}" FontWeight="{StaticResource HeaderTextFontWeight}" HorizontalAlignment="Center" Margin="0 2 0 0" Text="{TemplateBinding Content}" VerticalAlignment="Center"/>
                            <TextBlock x:Name="ForegroundText" Foreground="{StaticResource HeaderTextForeground}" FontWeight="{StaticResource HeaderTextFontWeight}" HorizontalAlignment="Center" Margin="0 1 0 1" Text="{TemplateBinding Content}" VerticalAlignment="Center"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="MoveRightButtonStyle" TargetType="RepeatButton">
            <Setter Property="Width" Value="22"/>
            <Setter Property="Height" Value="22"/>
            <Setter Property="Margin" Value="3"/>
            <Setter Property="IsTabStop" Value="False"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="RepeatButton">
                        <Grid Background="Transparent">
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="BackgroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconBackground_Disabled}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ForegroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconForeground_Disabled}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Normal"/>
                                    <VisualState x:Name="MouseOver">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="BackgroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconBackground_MouseOver}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ForegroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconForeground_MouseOver}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Pressed">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="BackgroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconBackground_Pressed}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ForegroundIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource HeaderButtonIconForeground_Pressed}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Chromes:ButtonChrome CornerRadius="{StaticResource SplitButton_SpanCornerRadius}" RenderMouseOver="{TemplateBinding IsMouseOver}" RenderPressed="{TemplateBinding IsPressed}" RenderFocused="{TemplateBinding IsFocused}" Style="{StaticResource HeaderButtonChrome}"/>
                            <Path x:Name="BackgroundIcon" Data="M0,0 L0,7 1,7 1,6 2,6 2,5 3,5 3,4 4,4 4,3 3,3 3,2 2,2 2,1 1,1 1,0 z" Fill="{StaticResource HeaderButtonIconBackground_Normal}" Height="7" Margin="0 2 0 0" Width="4"/>
                            <Path x:Name="ForegroundIcon" Data="M0,0 L0,7 1,7 1,6 2,6 2,5 3,5 3,4 4,4 4,3 3,3 3,2 2,2 2,1 1,1 1,0 z" Fill="{StaticResource HeaderButtonIconForeground_Normal}" Height="7" Margin="0 1 0 1" Width="4"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <CornerRadius x:Key="CalendarHeaderInnerCornerRadius">0</CornerRadius>
        <CornerRadius x:Key="CalendarHeaderOuterCornerRadius">0</CornerRadius>
        <Style x:Key="RadCalendarStyle" TargetType="telerik:RadCalendar">
            <Setter Property="Columns" Value="1"/>
            <Setter Property="Rows" Value="1"/>
            <Setter Property="Foreground" Value="{StaticResource PickerForeground_Normal}"/>
            <Setter Property="MonthViewStyle" Value="{StaticResource MonthViewStyle}"/>
            <Setter Property="YearViewStyle" Value="{StaticResource CalendarViewStyle}"/>
            <Setter Property="DecadeViewStyle" Value="{StaticResource CalendarViewStyle}"/>
            <Setter Property="CenturyViewStyle" Value="{StaticResource CalendarViewStyle}"/>
            <Setter Property="DayButtonStyle" Value="{StaticResource CalendarButtonStyle}"/>
            <Setter Property="MonthButtonStyle" Value="{StaticResource CalendarButtonStyle}"/>
            <Setter Property="YearButtonStyle" Value="{StaticResource CalendarButtonStyle}"/>
            <Setter Property="DecadeButtonStyle" Value="{StaticResource CalendarButtonStyle}"/>
            <Setter Property="Background" Value="{StaticResource PanelBackground}"/>
            <Setter Property="BorderBrush" Value="{StaticResource CalendarOuterBorder}"/>
            <Setter Property="BorderThickness" Value="1"/>
            <Setter Property="Padding" Value="{StaticResource CalendarHeaderPadding}"/>
            <Setter Property="ViewsHeaderVisibility" Value="Collapsed"/>
            <Setter Property="TabNavigation" Value="Once"/>
            <Setter Property="IsTabStop" Value="True"/>
            <Setter Property="TabIndex" Value="0"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="telerik:RadCalendar">
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="*"/>
                            </Grid.RowDefinitions>
                            <Border x:Name="Background" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Grid.RowSpan="2"/>
                            <Calendar:TransitionPanel x:Name="TransitionPanel" ClipToBounds="True" Margin="{StaticResource CalendarTransitionPanelMargin}" Grid.Row="1">
                                <telerik:RadUniformGrid x:Name="MonthViews" Columns="{TemplateBinding Columns}" Margin="1 1 0 0" Rows="{TemplateBinding Rows}"/>
                                <telerik:RadUniformGrid x:Name="YearViews" Columns="{TemplateBinding Columns}" Margin="1 1 0 0" Rows="{TemplateBinding Rows}" Visibility="Collapsed"/>
                                <telerik:RadUniformGrid x:Name="DecadeViews" Columns="{TemplateBinding Columns}" Margin="1 1 0 0" Rows="{TemplateBinding Rows}" Visibility="Collapsed"/>
                                <telerik:RadUniformGrid x:Name="CenturyViews" Columns="{TemplateBinding Columns}" Margin="1 1 0 0" Rows="{TemplateBinding Rows}" Visibility="Collapsed"/>
                            </Calendar:TransitionPanel>
                            <Border x:Name="OuterBorder" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="{StaticResource CalendarOuterBorderCornerRadius}" Grid.RowSpan="2">
                                <Border x:Name="InnerBorder" BorderBrush="{StaticResource CalendarInnerBorder}" BorderThickness="1" CornerRadius="{StaticResource CalendarInnerBorderCornerRadius}"/>
                            </Border>
                            <Border x:Name="Navigation" BorderBrush="{StaticResource HeaderOuterBorder}" BorderThickness="{StaticResource CalendarHeaderBorderThickness}" Background="{StaticResource HeaderBackground}" CornerRadius="{StaticResource CalendarHeaderOuterCornerRadius}" Margin="0 0 0 -1" Visibility="{TemplateBinding HeaderVisibility}" Canvas.ZIndex="2">
                                <Border BorderBrush="{StaticResource HeaderInnerBorder}" BorderThickness="{StaticResource CalendarHeaderBorderThickness}" CornerRadius="{StaticResource CalendarHeaderInnerCornerRadius}" Padding="{TemplateBinding Padding}">
                                    <Grid>
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition Width="Auto"/>
                                            <ColumnDefinition Width="*"/>
                                            <ColumnDefinition Width="Auto"/>
                                        </Grid.ColumnDefinitions>
                                        <RepeatButton x:Name="MoveLeft" Grid.Column="0" Style="{StaticResource MoveLeftButtonStyle}"/>
                                        <Button x:Name="Header" Grid.Column="1" Style="{StaticResource CalendarHeaderButton}"/>
                                        <RepeatButton x:Name="MoveRight" Grid.Column="2" Style="{StaticResource MoveRightButtonStyle}"/>
                                    </Grid>
                                </Border>
                            </Border>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="MonthViewPanel">
                <Setter.Value>
                    <ItemsPanelTemplate>
                        <Calendar:CalendarPanel Columns="8" FirstColumn="1" PreserveSpaceForCollapsedChildren="True" Rows="7" VerticalAlignment="Stretch"/>
                    </ItemsPanelTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="YearViewPanel">
                <Setter.Value>
                    <ItemsPanelTemplate>
                        <Calendar:CalendarPanel Columns="4" PreserveSpaceForCollapsedChildren="True" Rows="3" VerticalAlignment="Stretch"/>
                    </ItemsPanelTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="DecadeViewPanel">
                <Setter.Value>
                    <ItemsPanelTemplate>
                        <Calendar:CalendarPanel Columns="4" PreserveSpaceForCollapsedChildren="True" Rows="3" VerticalAlignment="Stretch"/>
                    </ItemsPanelTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="CenturyViewPanel">
                <Setter.Value>
                    <ItemsPanelTemplate>
                        <Calendar:CalendarPanel Columns="4" PreserveSpaceForCollapsedChildren="True" Rows="3" VerticalAlignment="Stretch"/>
                    </ItemsPanelTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <SolidColorBrush x:Key="PanelBorderBrush" Color="#FF848484"/>
        <SolidColorBrush x:Key="ClockBackground" Color="#FFFFFFFF"/>
        <SolidColorBrush x:Key="ClockInnerBorderBrush" Color="White"/>
        <CornerRadius x:Key="ClockInnerBorderCornerRadius">0</CornerRadius>
        <CornerRadius x:Key="ClockOuterBorderCornerRadius">0</CornerRadius>
        <Thickness x:Key="ClockItemsMargin">1 0 1 1</Thickness>
        <Style x:Key="RadClockStyle" TargetType="telerik:RadClock">
            <Setter Property="HorizontalContentAlignment" Value="Center"/>
            <Setter Property="VerticalContentAlignment" Value="Center"/>
            <Setter Property="BorderBrush" Value="{StaticResource PanelBorderBrush}"/>
            <Setter Property="Background" Value="{StaticResource ClockBackground}"/>
            <Setter Property="BorderThickness" Value="1"/>
            <Setter Property="Padding" Value="{StaticResource CalendarHeaderPadding}"/>
            <Setter Property="IsTabStop" Value="True"/>
            <Setter Property="TabIndex" Value="1"/>
            <Setter Property="StartTime" Value="0:0:0"/>
            <Setter Property="EndTime" Value="23:59:0"/>
            <Setter Property="TabNavigation" Value="Once"/>
            <Setter Property="ItemsPanel">
                <Setter.Value>
                    <ItemsPanelTemplate>
                        <telerik:RadUniformGrid x:Name="uniformGrid" Columns="4"/>
                    </ItemsPanelTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="ItemTemplate">
                <Setter.Value>
                    <DataTemplate>
                        <TextBlock x:Name="ContentText" HorizontalAlignment="Center" TextAlignment="Center" Text="{Binding}" VerticalAlignment="Center"/>
                    </DataTemplate>
                </Setter.Value>
            </Setter>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="telerik:RadClock">
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="*"/>
                            </Grid.RowDefinitions>
                            <Border x:Name="BackgroundVisual" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" CornerRadius="{StaticResource ClockOuterBorderCornerRadius}" Grid.RowSpan="2">
                                <Border BorderBrush="{StaticResource ClockInnerBorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="{StaticResource ClockInnerBorderCornerRadius}"/>
                            </Border>
                            <Border x:Name="Header" BorderBrush="{StaticResource HeaderOuterBorder}" BorderThickness="{StaticResource CalendarHeaderBorderThickness}" Background="{StaticResource HeaderBackground}" CornerRadius="{StaticResource CalendarHeaderOuterCornerRadius}" MinHeight="32">
                                <Border BorderBrush="{StaticResource HeaderInnerBorder}" BorderThickness="{StaticResource CalendarHeaderBorderThickness}" CornerRadius="{StaticResource CalendarHeaderInnerCornerRadius}" Padding="{TemplateBinding Padding}">
                                    <ContentControl ContentTemplate="{TemplateBinding HeaderTemplate}" Content="{TemplateBinding Header}" Foreground="{StaticResource HeaderTextForeground}" FontWeight="{StaticResource HeaderTextFontWeight}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" IsTabStop="False" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
                                </Border>
                            </Border>
                            <ItemsPresenter Margin="{StaticResource ClockItemsMargin}" Grid.Row="1"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Thickness x:Key="Tooltip_OuterBorderThickness">1</Thickness>
        <LinearGradientBrush x:Key="TooltipBackground" EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="#FFFFFFFF" Offset="0"/>
            <GradientStop Color="#FFDEDEDE" Offset="1"/>
        </LinearGradientBrush>
        <SolidColorBrush x:Key="Tooltip_OuterBorderBrush" Color="#FF848484"/>
        <SolidColorBrush x:Key="TooltipForeground" Color="#FF000000"/>
        <DataTemplate x:Key="TooltipTemplate">
            <Border CornerRadius="3" Margin="2">
                <Border BorderBrush="{x:Null}" BorderThickness="{StaticResource Tooltip_OuterBorderThickness}" Background="{StaticResource TooltipBackground}" CornerRadius="2" Margin="-3">
                    <Border BorderBrush="{StaticResource Tooltip_OuterBorderBrush}" BorderThickness="{StaticResource Tooltip_OuterBorderThickness}" CornerRadius="1">
                        <ContentControl Content="{Binding}" Foreground="{StaticResource TooltipForeground}" Margin="5 2"/>
                    </Border>
                </Border>
            </Border>
        </DataTemplate>
        <SolidColorBrush x:Key="PickerBackground_Normal" Color="#FFFFFFFF"/>
        <SolidColorBrush x:Key="ControlOuterBorder_Normal" Color="#FF848484"/>
        <DataTemplate x:Key="WatermarkTemplate">
            <TextBlock Opacity="1" Text="{Binding}"/>
        </DataTemplate>
        <SolidColorBrush x:Key="ControlOuterBorder_MouseOver" Color="#FFFFC92B"/>
        <SolidColorBrush x:Key="ControlOuterBorder_Focused" Color="#FFFFC92B"/>
        <SolidColorBrush x:Key="ControlInnerBorder_Focused" Color="Transparent"/>
        <CornerRadius x:Key="SplitButton_SpanInnerCornerRadius">0</CornerRadius>
        <CornerRadius x:Key="SplitButton_RightPartCornerRadius">0 1 1 0</CornerRadius>
        <SolidColorBrush x:Key="ButtonIconBackground_Normal" Color="#FFFFFFFF"/>
        <SolidColorBrush x:Key="ButtonIconForeground_Normal" Color="#FF000000"/>
        <ControlTemplate x:Key="CalendarIcon" TargetType="ContentControl">
            <Grid>
                <Path x:Name="CalendarIconBackground" Data="M0,0.5 L7,0.5 M0,2.5 L7,2.5 M0,4.5 L7,4.5 M0,6.5 L7,6.5 M0.5,0 L0.5,7 M2.5,0 L2.5,7 M4.5,0 L4.5,7 M6.5,0 L6.5,7" Height="7" Margin="4 5 4 4" Stroke="{TemplateBinding Background}" Width="7"/>
                <Path x:Name="CalendarIconForeground" Data="M0,0.5 L7,0.5 M0,2.5 L7,2.5 M0,4.5 L7,4.5 M0,6.5 L7,6.5 M0.5,0 L0.5,7 M2.5,0 L2.5,7 M4.5,0 L4.5,7 M6.5,0 L6.5,7" Height="7" Margin="4 4 4 5" Stroke="{TemplateBinding Foreground}" Width="7"/>
            </Grid>
        </ControlTemplate>
        <Style x:Key="CloseButtonStyle" TargetType="telerik:RadToggleButton">
            <Setter Property="IsTabStop" Value="True"/>
            <Setter Property="TabIndex" Value="2"/>
            <Setter Property="TabNavigation" Value="Once"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="telerik:RadToggleButton">
                        <Grid>
                            <Chromes:ButtonChrome RenderNormal="False" RenderMouseOver="{TemplateBinding IsMouseOver}" RenderPressed="{TemplateBinding IsPressed}" RenderFocused="{TemplateBinding IsFocused}" telerik:StyleManager.Theme="{StaticResource Theme}"/>
                            <ContentPresenter Margin="{TemplateBinding Padding}"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <SolidColorBrush x:Key="ButtonIconForeground_MouseOver" Color="#FF000000"/>
        <SolidColorBrush x:Key="ButtonIconBackground_MouseOver" Color="#FFFFFFFF"/>
        <SolidColorBrush x:Key="ControlOuterBorder_Disabled" Color="#FF989898"/>
        <Style x:Key="MikeStyle" TargetType="telerik:RadDateTimePicker">
            <Setter Property="CalendarStyle" Value="{StaticResource RadCalendarStyle}"/>
            <Setter Property="ClockStyle" Value="{StaticResource RadClockStyle}"/>
            <Setter Property="TabNavigation" Value="Once"/>
            <Setter Property="IsTabStop" Value="False"/>
            <Setter Property="TooltipTemplate" Value="{StaticResource TooltipTemplate}"/>
            <Setter Property="Background" Value="{StaticResource PickerBackground_Normal}"/>
            <Setter Property="Foreground" Value="{StaticResource PickerForeground_Normal}"/>
            <Setter Property="BorderBrush" Value="{StaticResource ControlOuterBorder_Normal}"/>
            <Setter Property="BorderThickness" Value="1"/>
            <Setter Property="FontStyle" Value="Normal"/>
            <Setter Property="FontWeight" Value="Normal"/>
            <Setter Property="MinHeight" Value="22"/>
            <Setter Property="Padding" Value="4 2"/>
            <Setter Property="VerticalContentAlignment" Value="Center"/>
            <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
            <Setter Property="BorderThickness" Value="1"/>
            <Setter Property="DateTimeWatermarkTemplate" Value="{StaticResource WatermarkTemplate}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="telerik:RadDateTimePicker">
                        <Grid>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition/>
                                <ColumnDefinition Width="auto"/>
                            </Grid.ColumnDefinitions>
                            <VisualStateManager.VisualStateGroups>
                                <VisualStateGroup x:Name="CommonStates">
                                    <VisualState x:Name="Normal">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="MouseOverVisual">
                                                <DiscreteObjectKeyFrame KeyTime="00:00:00.150">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Collapsed</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="MouseOverVisual">
                                                <LinearDoubleKeyFrame KeyTime="00:00:00.150" Value="0"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="RenderEnabled" Storyboard.TargetName="ButtonChrome">
                                                <DiscreteObjectKeyFrame KeyTime="0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <System:Boolean>True</System:Boolean>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="MouseOver">
                                        <Storyboard>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="MouseOverVisual">
                                                <LinearDoubleKeyFrame KeyTime="0:0:0.115" Value="1"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="MouseOverVisual">
                                                <DiscreteObjectKeyFrame KeyTime="0:0:0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Visible</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="RenderActive" Storyboard.TargetName="ButtonChrome">
                                                <DiscreteObjectKeyFrame KeyTime="0:0:0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <System:Boolean>True</System:Boolean>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="DropDownIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonIconForeground_MouseOver}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="DropDownIcon">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource ButtonIconBackground_MouseOver}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="RenderEnabled" Storyboard.TargetName="ButtonChrome">
                                                <DiscreteObjectKeyFrame KeyTime="0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <System:Boolean>True</System:Boolean>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Disabled">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="BackgroundVisual">
                                                <DiscreteObjectKeyFrame KeyTime="0:0:0" Value="{StaticResource ControlOuterBorder_Disabled}"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="MouseOverVisual">
                                                <LinearDoubleKeyFrame KeyTime="0:0:0.050" Value="0"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="MouseOverVisual">
                                                <DiscreteObjectKeyFrame KeyTime="0:0:0.050">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Collapsed</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity" Storyboard.TargetName="DropDownIcon">
                                                <LinearDoubleKeyFrame KeyTime="00:00:00.150" Value="0.5"/>
                                            </DoubleAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="RenderEnabled" Storyboard.TargetName="ButtonChrome">
                                                <DiscreteObjectKeyFrame KeyTime="0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <System:Boolean>False</System:Boolean>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="FocusStates">
                                    <VisualState x:Name="Focused">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="RenderFocused" Storyboard.TargetName="ButtonChrome">
                                                <DiscreteObjectKeyFrame KeyTime="0:0:0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <System:Boolean>False</System:Boolean>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="FocusVisual">
                                                <DiscreteObjectKeyFrame KeyTime="00:00:00.115">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Visible</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="Unfocused"/>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="InputTypeStates">
                                    <VisualState x:Name="DateTimePicker"/>
                                    <VisualState x:Name="DatePicker">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="PART_Clock">
                                                <DiscreteObjectKeyFrame KeyTime="0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Collapsed</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="CloseButtonContainer">
                                                <DiscreteObjectKeyFrame KeyTime="0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Collapsed</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="TimePicker">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="CloseButtonContainer">
                                                <DiscreteObjectKeyFrame KeyTime="0">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <Visibility>Collapsed</Visibility>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                                <VisualStateGroup x:Name="ValidationStates">
                                    <VisualState x:Name="Valid"/>
                                    <VisualState x:Name="InvalidUnfocused">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="ValidationTooltip">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                    <VisualState x:Name="InvalidFocused">
                                        <Storyboard>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="ValidationTooltip">
                                                <DiscreteObjectKeyFrame KeyTime="0" Value="Visible"/>
                                            </ObjectAnimationUsingKeyFrames>
                                            <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="IsOpen" Storyboard.TargetName="ValidationTooltip">
                                                <DiscreteObjectKeyFrame KeyTime="0:0:0.1">
                                                    <DiscreteObjectKeyFrame.Value>
                                                        <System:Boolean>True</System:Boolean>
                                                    </DiscreteObjectKeyFrame.Value>
                                                </DiscreteObjectKeyFrame>
                                            </ObjectAnimationUsingKeyFrames>
                                        </Storyboard>
                                    </VisualState>
                                </VisualStateGroup>
                            </VisualStateManager.VisualStateGroups>
                            <Border x:Name="BackgroundVisual" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Grid.ColumnSpan="2" CornerRadius="{StaticResource SplitButton_SpanCornerRadius}"/>
                            <Border x:Name="MouseOverVisual" BorderBrush="{StaticResource ControlOuterBorder_MouseOver}" BorderThickness="{TemplateBinding BorderThickness}" Grid.ColumnSpan="2" CornerRadius="{StaticResource SplitButton_SpanCornerRadius}" IsHitTestVisible="False" Opacity="0" Visibility="Collapsed"/>
                            <telerik:RadWatermarkTextBox x:Name="PART_DateTimeInput" BorderBrush="{x:Null}" BorderThickness="0" Background="{x:Null}" Grid.Column="0" CurrentText="{Binding CurrentDateTimeText, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" IsReadOnly="{TemplateBinding IsReadOnly}" Margin="{TemplateBinding BorderThickness}" MinHeight="0" Padding="{TemplateBinding Padding}" SelectionOnFocus="{TemplateBinding SelectionOnFocus}" TextAlignment="{TemplateBinding TextAlignment}"
                                                         Text="{Binding DateTimeText,
                                Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" telerik:StyleManager.Theme="{StaticResource Theme}" TabIndex="0" VerticalAlignment="Stretch" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" WatermarkTemplate="{TemplateBinding DateTimeWatermarkTemplate}" WatermarkContent="{TemplateBinding DateTimeWatermarkContent}"/>
                            <Border x:Name="FocusVisual" BorderBrush="{StaticResource ControlOuterBorder_Focused}" BorderThickness="{TemplateBinding BorderThickness}" Grid.ColumnSpan="2" CornerRadius="{StaticResource SplitButton_SpanCornerRadius}" IsHitTestVisible="False" Visibility="Collapsed">
                                <Border BorderBrush="{StaticResource ControlInnerBorder_Focused}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="{StaticResource SplitButton_SpanInnerCornerRadius}"/>
                            </Border>
                            <telerik:RadDropDownButton x:Name="PART_DropDownButton" CloseOnEnter="True" Grid.Column="2" DropDownIndicatorVisibility="Collapsed" telerik:DateTimePickerExtensions.FocusContentOnOpen="True" HorizontalAlignment="Stretch" HorizontalContentAlignment="Stretch" IsTabStop="False" IsOpen="{Binding IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" Margin="-1 0 0 0" Padding="0" PopupPlacementTarget="{Binding ElementName=PART_DateTimeInput}" telerik:StyleManager.Theme="{StaticResource Theme}" TabIndex="1" VerticalAlignment="Stretch" VerticalContentAlignment="Stretch">
                                <telerik:RadDropDownButton.DropDownContent>
                                    <Grid>
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition Width="*"/>
                                            <ColumnDefinition Width="*"/>
                                        </Grid.ColumnDefinitions>
                                        <Grid.RowDefinitions>
                                            <RowDefinition/>
                                            <RowDefinition/>
                                        </Grid.RowDefinitions>
                                        <telerik:DateTimePickerClock x:Name="PART_Clock" Culture="{TemplateBinding Culture}" Grid.Column="1" EndTime="{TemplateBinding EndTime}" IsReadOnly="{TemplateBinding IsReadOnly}" ItemsSource="{TemplateBinding ClockItemsSource}" Grid.Row="0" Style="{TemplateBinding ClockStyle}"
                                                                     SelectedItem="{Binding SelectedTime, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"
 StartTime="{TemplateBinding StartTime}" TimeInterval="{Binding TimeInterval, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}"/>
                                        <Border x:Name="CloseButtonContainer" BorderBrush="{StaticResource CalendarOuterBorder}" BorderThickness="1 0 1 1" Background="{StaticResource PanelBackground}" Grid.ColumnSpan="2" Grid.Row="1">
                                            <Border BorderBrush="{StaticResource CalendarInnerBorder}" BorderThickness="1 0 1 1">
                                                <telerik:RadToggleButton x:Name="PART_Close" HorizontalAlignment="Right" IsThreeState="False" IsBackgroundVisible="False" IsChecked="{Binding IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" Margin="2" Padding="8 3" telerik:LocalizationManager.ResourceKey="Close" Style="{StaticResource CloseButtonStyle}"/>
                                            </Border>
                                        </Border>
                                    </Grid>
                                </telerik:RadDropDownButton.DropDownContent>
                                <telerik:RadDropDownButton.Template>
                                    <ControlTemplate TargetType="telerik:RadDropDownButton">
                                        <Grid>
                                            <ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
                                            <telerik:Popup x:Name="DropDownPopup">
                                                <ContentPresenter x:Name="DropDownPopupContent" ContentTemplate="{TemplateBinding DropDownContentTemplate}" Content="{TemplateBinding DropDownContent}" DataContext="{Binding DataContext, RelativeSource={RelativeSource TemplatedParent}}"/>
                                            </telerik:Popup>
                                        </Grid>
                                    </ControlTemplate>
                                </telerik:RadDropDownButton.Template>
                                <Grid>
                                    <Chromes:ButtonChrome x:Name="ButtonChrome" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" CornerRadius="{StaticResource SplitButton_RightPartCornerRadius}" RenderMouseOver="{Binding IsMouseOver, ElementName=PART_DropDownButton}" telerik:StyleManager.Theme="{StaticResource Theme}"/>
                                    <ContentControl x:Name="DropDownIcon" Background="{StaticResource ButtonIconBackground_Normal}" Foreground="{StaticResource ButtonIconForeground_Normal}" IsTabStop="False" Template="{StaticResource CalendarIcon}"/>
                                </Grid>
                            </telerik:RadDropDownButton>
                            <Chromes:ValidationTooltip x:Name="ValidationTooltip" Grid.ColumnSpan="2" TooltipPlacementTarget="{Binding RelativeSource={RelativeSource TemplatedParent}}" telerik:StyleManager.Theme="{StaticResource Theme}" TooltipContent="{Binding (Validation.Errors), RelativeSource={RelativeSource TemplatedParent}}" Visibility="Collapsed"/>
                            <telerik:Popup IsOpen="{Binding IsTooltipOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" Owner="{Binding RelativeSource={RelativeSource TemplatedParent}}" Placement="Top">
                                <telerik:PopupPlacement.PopupPlacement>
                                    <telerik:PopupPlacement PlacementTarget="{Binding ElementName=PART_DateTimeInput}"/>
                                </telerik:PopupPlacement.PopupPlacement>
                                <ContentPresenter ContentTemplate="{TemplateBinding TooltipTemplate}" Content="{TemplateBinding TooltipContent}"/>
                            </telerik:Popup>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
    </UserControl.Resources>

    <Grid x:Name="LayoutRoot" Background="White">
        <telerik:RadTimePicker  x:Name="timePicker"
                                Height="20"
                                Width="100"
                                SelectedTime="{Binding SelectedTime2, Mode=TwoWay}"
                                TimeInterval="0:30"
                                 Style="{StaticResource MikeStyle}" />
    </Grid>
</UserControl>

if you remove Style="{StaticResource MikeStyle}" it works.

I'm not doing anything special in the binding just a Timespan on MainPage.xaml called ReceievedTime
<radTimePickerTest:TimerPicker SelectedTime2="{Binding ReceievedTime, Mode=TwoWay}" />
And a SelectedTime2 with SelectedTime2Property dependancy property on the user control.

Like I say everything works as expected without the style.

Please could you offer any kind of solution?

Thanks
Andy Poulton
Top achievements
Rank 1
 answered on 15 Dec 2014
4 answers
272 views
Hello,

I have C# application that uses the RadDatePicker and the RadTimePicker. Here is the XAML I will be referencing:
<telerik:RadDatePicker x:Name="myDatePicker" DateTimeWatermarkContent="MM/DD/YY" />
<telerik:RadTimePicker x:Name="myTimePicker" DateTimeWatermarkContent="HH:MM:SS" StartTime="0:0:0" EndTime="23:0:0" Culture="en-US" />

I need to programmatically set the selected TIME of "myTimePicker". In an attempt to do this, I am using the following:
myDatePicker.SelectedDate = MyDateTimeProp.Date;
myTimePicker.SelectedTime = MyDateTimeProp.TimeOfDay;

Oddly, the correct date appears in the RadDatePicker, but the time is not displayed in the RadTimePicker. How do I programmatically set the time displayed in the RadTimePicker? 

Thank you
Yana
Telerik team
 answered on 03 Jul 2014
3 answers
184 views
How can i create a Rad Time Picker in RadGrid that gives me 24 hours in military style and also it has to have 30 min. interval starting from 04:00 to 03:30 next day.

Anybody has any idea how to do this.


Thank you in advance.
Kalin
Telerik team
 answered on 17 Jun 2013
5 answers
133 views
Hi:

i would like to be able to increase the time picker time by 15 minutes by typing a plus or by hitting an up-arrow.  Similarly, reduce the time by 15 minutes by hitting the minus key or a down-arrow.  Is it possible to do this?

Thanks,

Terry
Nimesh
Top achievements
Rank 1
 answered on 29 Jul 2012
8 answers
98 views
I've customized the header of the picker with the :
<telerikCtrl:RadTimePicker.ClockStyle>
    <Style TargetType="telerikCtrl:RadClock">
         <Setter Property="Header" Value="Durée" />
    </Style>
</telerikCtrl:RadTimePicker.ClockStyle>

But I'm unable to find a way to edit the "Close" button.
Can you confirm the approach, or provide another method ?

Regards,
Peter
Top achievements
Rank 1
 answered on 27 Apr 2012
1 answer
39 views
I need a range of time customized (visually) , for example that will start at 06:00:00 and end at 29:59:59 (24 hours within the range).

Have you think of a control for this? How can it be done?


Thanks!  
Georgi
Telerik team
 answered on 16 Mar 2012
3 answers
166 views
Do you have a control that display TIME SPAN???

Thanks,
Ivo
Telerik team
 answered on 07 Mar 2012
1 answer
63 views
Hi,

I need an XAML solution for the following situation:

In my grid are two TimePickers named BeginTime and EndTime. The selected time of the EndTime can't be earlier than the BeginTime.

Is this possible to do this check into the XAML?

An example would be appreciated.

Thanks in advance.
Georgi
Telerik team
 answered on 22 Feb 2012
7 answers
115 views
Hi there,

I have installed the latest version of telerik radcontrols for silverlight i.e. Q1 2011. I have upgraded my project with the latest binaries and i have started getting the below error.

The property 'ClockPanel' does not exist on the type 'RadTimePicker' in the XML namespace 'http://schemas.telerik.com/2008/xaml/presentation'.

Below is my code which use to work with Q3 2010

<

 

 

telerik:RadTimePicker Grid.Row="1" Grid.Column="1" x:Name="TpSunFrom" StartTime="0:0:0" TimeInterval="0:15:0" EndTime="23:59:0" Width="100" Culture="en-US" HorizontalAlignment="Left" VerticalAlignment="Center">

 

 

 

 

<telerik:RadTimePicker.ClockPanel>

 

 

 

 

<ItemsPanelTemplate>

 

 

 

 

<telerik:RadUniformGrid Columns="2"/>

 

 

 

 

</ItemsPanelTemplate>

 

 

 

 

</telerik:RadTimePicker.ClockPanel>

 

 

 

 

</telerik:RadTimePicker>

 


Thank you,
Ivan Paul
Konstantina
Telerik team
 answered on 15 Dec 2011
1 answer
61 views
Using military time format:
    If I want to put in 00:30,  I need to type 00:30 or 24:30 to get the control to have the correct time.  If I just put in 0030 or 30 or 030 it sets the time to 03:00 
    Is there anything to set on the control that would change this?  I use this control in multiple places in my application so writing extra code for each instance isn't a good solution.

Thanks
Konstantina
Telerik team
 answered on 01 Sep 2011
Top users last month
Dominik
Top achievements
Rank 1
Giuliano
Top achievements
Rank 1
Dominic
Top achievements
Rank 1
Glendys
Top achievements
Rank 1
NoobMaster
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?