ComponentOne DataGrid for WPF and Silverlight
DataGrid for WPF and Silverlight Overview / DataGrid Features / Filtering / Full Text Grid Filtering
In This Topic
    Full Text Grid Filtering
    In This Topic

    C1DataGrid also supports full text filtering for the entire grid. Setting an attached property to the data grid allows the end user to filter the whole data grid (all the columns at once) by text entered in an external text box. All the matching results in the grid will be highlighted as the user types.

    To use this method of grid filtering, you would need to add a text box control to your application and reference that control in the FullTextSearchBehavior attached property. For example, with the following XAML markup:

    XAML
    Copy Code
    <StackPanel>
        <c1:C1TextBoxBase x:Name="filterTextBox" Width="200" Watermark = "Type here to filter text"/>
        <c1:C1DataGrid x:Name="c1dg" c1:C1NagScreen.Nag="True">
        < c1:C1FullTextSearchBehavior.FullTextSearchBehavior>
            < c1:C1FullTextSearchBehavior Filter="{Binding ElementName=filterTextBox,Path=C1Text}"/>
        < /c1:C1FullTextSearchBehavior.FullTextSearchBehavior>
    </c1:C1DataGrid>
    </StackPanel>
    

    You can see the C1DataGrid_Demo2010/Filtering/OneTextBoxFilter/OneTextBoxFilter.xaml sample for an example.