
Jerry Kurata
Top achievements
Rank 1
Jerry Kurata
asked on 21 Apr 2011, 04:33 PM
Hi,
I have a custom filter dialog through which the user enters filter criteria. Based on this criteria I perform my own filtering of the underlying itemsource for the grid. I would like to turn on the funnel icon for the columns the user has used to filter the data. Can someone show how I can do this?
Thanks,
Jerry
I have a custom filter dialog through which the user enters filter criteria. Based on this criteria I perform my own filtering of the underlying itemsource for the grid. I would like to turn on the funnel icon for the columns the user has used to filter the data. Can someone show how I can do this?
Thanks,
Jerry
4 Answers, 1 is accepted
0
Hello Jerry Kurata,
You need to add a ColumnFilterDescriptor for each column to the RadGridView.
Greetings,
Yavor Georgiev
the Telerik team
You need to add a ColumnFilterDescriptor for each column to the RadGridView.
Greetings,
Yavor Georgiev
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
0

Jerry Kurata
Top achievements
Rank 1
answered on 21 Apr 2011, 05:38 PM
Yavor,
So the ColumnFilteringDescriptor is required even if I am doing the filtering (via Linq) in other parts of my code? If so, I assume that the descriptor would be initialized, but none of the .FieldFilter values would be set. Is that correct?
Thanks,
jerry
So the ColumnFilteringDescriptor is required even if I am doing the filtering (via Linq) in other parts of my code? If so, I assume that the descriptor would be initialized, but none of the .FieldFilter values would be set. Is that correct?
Thanks,
jerry
0
Accepted
Hi Jerry Kurata,
I apologize for misunderstanding your question. If you already apply filtering externally, you only need to handle the CellLoaded event like so:
Regards,
Yavor Georgiev
the Telerik team
I apologize for misunderstanding your question. If you already apply filtering externally, you only need to handle the CellLoaded event like so:
void
gridView_CellLoaded(
object
sender, CellEventArgs e)
{
var cell = e.Cell
as
GridViewHeaderCell;
if
(cell !=
null
&& cell.Column.UniqueName ==
"UnitPrice"
)
{
if
(cell.DataColumn.FilteringControl ==
null
)
{
cell.DataColumn.FilteringControl =
new
FilteringControl();
}
this
.Dispatcher.BeginInvoke(() => cell.DataColumn.FilteringControl.IsActive =
true
));
}
}
Regards,
Yavor Georgiev
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
0

Jerry Kurata
Top achievements
Rank 1
answered on 21 Apr 2011, 10:28 PM
Thanks Yavor. Your code worked great!