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

Customize the Left Side?

1 Answer 20 Views
DataFilter
This is a migrated thread and some comments may be shown as answers.
Keith
Top achievements
Rank 1
Keith asked on 14 Dec 2011, 07:25 PM
Hi Telerik Team-

I am attempting to use a RadDataFilter control in unbound mode. We are only interested in using the control for its UI. Our product team asked us to display a popup window when the user attempts to select a field on the left side of the filter expression.

The specific control I am talking about is the control labeled 'Members DropDown' in this diagram.

http://www.telerik.com/help/silverlight/raddatafilter-visual-structure.html

I know there are some extension points for creating custom filter editors, is there a technique for custom field editors?

Thanks
Keith

1 Answer, 1 is accepted

Sort by
0
Rossen Hristov
Telerik team
answered on 15 Dec 2011, 10:04 AM
Hello Keith,

I am afraid that this would not be possible. RadDataFilter is tightly coupled with its underlying view models that are bound to and rely on the UI to create FilterDescriptors. If you dump all of the filtering logic that RadDataFilter performs, you would be left with a empty "dumb" tree-like control. So it will not be RadDataFilter anymore and there will be no one to create the FilterDescriptors.

In your case you would be better off if using some kind of generic "home-made" HeaderedItemsControl such as a a TreeView. You can of course "borrow" UI parts from RadDataFilter, i.e. the plus minus buttons and so forth.

However, if you still decide to replace the Member drop down with something else, you will have to make sure that the underlying view model receives a string with the member name. RadDataFilter can produce filters of the form Member-Operator-Value so you would have to supply a Member anyway. Take a look at the XAML and see how the Member combo-box is bound to the underlying view model.

I don't think that this task would be trivial though. My suggestion would be to use a generic TreeView for your custom purposes.

I hope this helps.

All the best,
Ross
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
DataFilter
Asked by
Keith
Top achievements
Rank 1
Answers by
Rossen Hristov
Telerik team
Share this question
or