Welcome to the Xceed Community | Help
Community Search  
More Search Options

How to align Checkbox in filterrow of Xceed datagrid for wpf?

Sort Posts: Previous Next
  •  05-14-2010, 1:37 PM Post no. 26837

    How to align Checkbox in filterrow of Xceed datagrid for wpf?

    I have a column with checkbox, all the checkbox are aligned in center, but the filterrow check box is aligned to left by default. How can we able to align the filterrow checkbox to center?

    Thanks in advance.

  •  05-14-2010, 5:07 PM Post no. 26840 in reply to 26837

    Re: How to align Checkbox in filterrow of Xceed datagrid for wpf?

     You achieve this by changing the control template of the FilterCell.

    Here's an example:

    <xcdg:FilterRow>

      <xcdg:FilterCell FieldName="IsBig">

        <xcdg:FilterCell.Template>

          <ControlTemplate TargetType="{x:Type xcdg:FilterCell}">

             <CheckBox HorizontalAlignment="Center"

                IsChecked="{Binding

                Path=Content,

                RelativeSource={RelativeSource

                AncestorType={x:Type xcdg:FilterCell}}}"/>

          </ControlTemplate>

        </xcdg:FilterCell.Template>

      </xcdg:FilterCell>

    </xcdg:FilterRow>


    Best Regards,

    Michel Dahdah
    Technical Support
    Xceed Software inc.
  •  05-14-2010, 5:55 PM Post no. 26841 in reply to 26840

    Re: How to align Checkbox in filterrow of Xceed datagrid for wpf?

    Hi Michel,

    Thankyou for the quick response. it worked fine Smile . 

    Can you please suggest do we have any option to implement the same in generic style , so that it can be applied for all the checkbox columns?

    Thanks

    Murali

View as RSS news feed in XML
Contact | Site Map | Reviews | Legal Terms of Use | Trademarks | Privacy Statement Copyright 2011 Xceed Software Inc.