01.
protected
virtual
void
filtering()
02.
{
03.
string
dataMember =
this
.columnFiltering.DataMemberBinding.Path.Path;
04.
05.
var items = from a
in
ItemsContainerListBox.ChildrenOfType<CheckBox>() where a.IsChecked ==
true
select (a.DataContext
as
customItem).Color;
06.
this
.compositeFilter.FilterDescriptors.Clear();
07.
08.
foreach
(var item
in
items)
09.
{
10.
Telerik.Windows.Data.FilterDescriptor filter =
new
Telerik.Windows.Data.FilterDescriptor(dataMember, Telerik.Windows.Data.FilterOperator.IsEqualTo,item);
11.
12.
this
.compositeFilter.FilterDescriptors.Add(filter);
13.
}
14.
15.
if
(!
this
.columnFiltering.DataControl.FilterDescriptors.Contains(
this
.compositeFilter))
16.
{
17.
this
.columnFiltering.DataControl.FilterDescriptors.Add(
this
.compositeFilter);
18.
}
19.
20.
this
.IsActive =
true
;
21.
22.
23.
}
good day:
I try make custom filteringControl with a listbox...
to filtering I use the code up side but just works with one option... if I select 2 o more, the items disappear of the grid
what I need to do?
thanks have a nice day.