This is a migrated thread and some comments may be shown as answers.

Filtering with List

1 Answer 43 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Jokerwolf
Top achievements
Rank 1
Jokerwolf asked on 21 Oct 2010, 07:54 AM

Hello,

Here is my question.

We have the GridView, and some columns are bound to the List<MyType>.We've made a custom filter like shown in some of your. demos. Now we need to filter those columns, but the DataMemberBinding is set to the List. Some code:

01.<DataTemplate x:Key="cellTemplate">
02. <DataTemplate.Resources>
03.  <my:PercentsConverter  x:Key="PerConv">
04. </DataTemplate.Resources>
05. <TextBlock>
06.  <TextBlock.Text>
07.   <MultiBinding Converter ="{StaticResource PerConv}" 
08.                 ConverterParameter="MyParam">
09.    <Binding Path="ListValues"/>
10.    <Binding Path="SomeValues"/>
11.   </MultiBinding>
12.  </TextBlock.Text>
13. </TextBlock>
14.</DataTemplate>

01.var tCol = new GridViewDataColumn()
02.{
03.     Header = temp.ToString(),
04.     CellTemplate = datatemplate,
05.     CellStyleSelector = new CellStyleSelector(),
06.     DataMemberBinding = new Binding("ListValues"),
07.     IsFilterable = true,
08.     FilteringControl = new Filtering()
09.     {
10.         Minimum = 0,
11.         Maximum = 100
12.     },
13.};
When we start the program there is no filter at these columns at all.

1 Answer, 1 is accepted

Sort by
0
Veselin Vasilev
Telerik team
answered on 26 Oct 2010, 10:07 AM
Hello Jokerwolf,

Probably there is something wrong with the custom filtering control. What happens if you do not set the FilteringControl property of the data column? Does the default built-in filtering work in this case?

Since we can only guess what is going on - I suggest that you open a separate support ticket and attach a sample project there so we can debug your code.

Kind regards,
Veselin Vasilev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
GridView
Asked by
Jokerwolf
Top achievements
Rank 1
Answers by
Veselin Vasilev
Telerik team
Share this question
or