Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
515
Column Header using Style
posted

Hi,

I am trying to customize column header using style. I want to put button for filter in the column header. But the the column default style must be maintained as such. So I tried doing in the below mentioned way:

<Style TargetType="{x:Type igDP:LabelPresenter}" >

<Setter Property="Template">

<Setter.Value>

<ControlTemplate TargetType="{x:Type igDP:LabelPresenter}">

<Grid>

<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center"/>

<Button Width="15" Height="15" x:Name="btnCol" HorizontalAlignment="Left" Click="btnCol_Click" >

</Button>

</Grid>

</ControlTemplate>

</Setter.Value>

</Setter>

</Style>

 but when this style is applied to LabelPresenter i am loosing the default look for Column. I mean I am not able to view "sorting" icon which appears bydefault in the column though sorting functionality is working fine.

Please need help for this.

Thanks,

Sejal