I followed the Custom Filtering Control in the GridView.
<
telerik:RadGridView
Name
=
"radGridView"
AutoGenerateColumns
=
"False"
>
<
telerik:RadGridView.Columns
>
<
telerik:GridViewDataColumn
DataMemberBinding
=
"{Binding FirstName}" Header="First Name" HeaderCellStyle="{StaticResource MyStyle}"
/>
<
telerik:GridViewDataColumn
DataMemberBinding
=
"{Binding LastName}" Header="Last Name" HeaderCellStyle="{StaticResource MyStyle}"
/>
<
telerik:GridViewDataColumn
DataMemberBinding
=
"{Binding HireDate}" Header="Hire Date " HeaderCellStyle="{StaticResource MyStyle}"
>
<
telerik:GridViewDataColumn.FilteringControl
>
<
local:FromDateToDateFilterControl
FromDate
=
"1/1/1990"
ToDate
=
"1/1/1995"
/>
</
telerik:GridViewDataColumn.FilteringControl
>
</
telerik:GridViewDataColumn
>
</
telerik:RadGridView.Columns
>
</
telerik:RadGridView
>
Also I set the style as
<
Style
x:Key
=
"MyStyle"
TargetType
=
"telerik:GridViewHeaderCell"
>
<
Setter
Property
=
"Foreground"
Value
=
"Black"
/>
<
Setter
Property
=
"Template"
Value
=
"{...}"
/>
</
Style
>
But I found the headers are not showing.
I saw the Template contains
<
ContentControl
x:Name
=
"ContentPresenter"
Contemplate
=
"{TemplateBinding ContentTemplate}"
Content
=
"{TemplateBinding Content}"
>
I found the content caused the problem. If I use the hard coded content then I can see the headers.
Many thanks for code help.