Hello,
I want to set a filter in a GridView on loading. After adding the filter, the data is reduced correctly, but the filter symbol don't change and i can't remove the filter.
Thanks!
example code:
I want to set a filter in a GridView on loading. After adding the filter, the data is reduced correctly, but the filter symbol don't change and i can't remove the filter.
Thanks!
example code:
public
MainPage()
{
InitializeComponent();
radGridView.DataLoaded += (s, e) =>
{
if
(!radGridView.FilterDescriptors.Any())
{
CompositeFilterDescriptor newFilter =
new
CompositeFilterDescriptor();
newFilter.FilterDescriptors.Add(
new
Telerik.Windows.Data.FilterDescriptor(
radGridView.Columns[0].UniqueName
, FilterOperator.Contains
,
"a"
));
radGridView.FilterDescriptors.Add(newFilter);
}
};
radGridView.ItemsSource =
new
List<String> {
"a"
,
"b"
,
"c"
};
}