This question is locked. New answers and comments are not allowed.
I am using several jumplists and so would like to have a style that I can easily apply and have consistency of look.
Most of the templates can be styled easily and attached thus:
With a styles.xaml file that looks like this:
All well and good however my question is how to style the PhoneBookTemplateSelector (copied from the example code supplied with the toolkit).
When I try to create a style for this I get an error saying 'Object reference not set'
The error occurs on the first Setter Property.
Is there a way to do this? Help or explanation gratefully received.
Most of the templates can be styled easily and attached thus:
<telerikData:RadJumpList x:Name="radJumpList" Style="{StaticResource radJumpStyleTitle}">With a styles.xaml file that looks like this:
<Style x:Key="radJumpStyleTitle" TargetType="telerikData:RadJumpList"> <Setter Property="ItemTemplate" Value="{StaticResource MyDataTemplateTitle}"/> <Setter Property="EmptyContentTemplate" Value="{StaticResource NoDataItemsTextBlock}" /> <Setter Property="GroupPickerItemsPanel" Value="{StaticResource radItemsWrapPanel}" /> <Setter Property="GroupHeaderTemplate" Value="{StaticResource radGroupHeaderTextBlock}"/> <Setter Property="ScrollBarMode" Value="AlwaysVisible" /> <Setter Property="HorizontalContentAlignment" Value="Stretch" /> <Setter Property="Margin" Value="12,17,0,28"/> </Style>All well and good however my question is how to style the PhoneBookTemplateSelector (copied from the example code supplied with the toolkit).
When I try to create a style for this I get an error saying 'Object reference not set'
<Style TargetType="local:PhoneBookTemplateSelector"> <Setter Property="LinkedItemTemplate" > <Setter.Value> <DataTemplate> <Border Background="{StaticResource PhoneAccentBrush}" Width="96" Height="96" Margin="6"> <TextBlock Margin="8" Text="{Binding}" HorizontalAlignment="Left" VerticalAlignment="Bottom" FontSize="{StaticResource PhoneFontSizeExtraLarge}"/> </Border> </DataTemplate> </Setter.Value> </Setter> <Setter Property="EmptyItemTemplate"> <Setter.Value> <DataTemplate> <Border Background="{StaticResource PhoneChromeBrush}" Width="96" Height="96" Margin="6" IsHitTestVisible="False"> <TextBlock Margin="8" Text="{Binding}" HorizontalAlignment="Left" VerticalAlignment="Bottom" FontSize="{StaticResource PhoneFontSizeExtraLarge}" Foreground="{StaticResource PhoneDisabledBrush}"/> </Border> </DataTemplate> </Setter.Value> </Setter></Style>The error occurs on the first Setter Property.
Is there a way to do this? Help or explanation gratefully received.
