Hi,
I am using telrik components for wpf. I want to get "Select all" Check Box on Grid Header cell
I have Common ResourceDictionary Style.Xaml , it has
<ResourceDictionary xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation">
<Style TargetType="telerik:GridViewHeaderCell">
<Setter Property="FontWeight" Value="ExtraLight" />
</Style>
</ResourceDictionary>
Im MyWindow.Xaml I have
<Window.Resources>
<Style x:Key="CheckBoxHeaderCellStyle" TargetType="telerik:GridViewHeaderCell">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="telerik:GridViewHeaderCell">
<CheckBox VerticalAlignment="Center"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</Window.Resources>
In code behind I am using
var dict = new ResourceDictionary
{
Source = new Uri("MyApp;component/View/styles.xaml", UriKind.Relative)
};
Resources.MergedDictionaries.Add(dict);
I apply style in GridDataColumn as
<telerik:GridViewDataColumn HeaderCellStyle="{StaticResource CheckBoxHeaderCellStyle}"/>
In design mode I can see the checkbox in Grid Header.But It does not show a check box in GridHeader.