This quick start will guide you through the steps of adding DataFilter and DataGridView controls to an application, binding DataGridView to a data source and setting the properties of controls. The below section gets you started with C1DataFilter in .NET and .NET Framework editions.
Complete the steps given below to see how the DataFilter control appears after data binding and setting properties.
The following image shows filtered values in DataGrid on the basis of filters applied in the DataFilter control.
XAML |
Copy Code
|
---|---|
<Window xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:local="clr-namespace:DataFilter_QuickStart" xmlns:c1="http://schemas.componentone.com/winfx/2006/xaml" x:Class="MainWindow" mc:Ignorable="d" Title="MainWindow" Height="450" Width="800"> <Grid> <c1:C1DataFilter FilterChanged="C1DataFilter_FilterChanged" Name="c1DataFilter" AutoGenerateFilters="True" FilterAutoGenerating="C1DataFilter_FilterAutoGenerating" HorizontalAlignment="Left" VerticalAlignment="Top" Height="419" Width="264"/> <DataGrid Name="dataGrid" HorizontalAlignment="Left" Height="419" Margin="267,0,0,0" VerticalAlignment="Top" Width="525"/> </Grid> </Window> |