Does anyone have a working example of saving the FilterDescriptors collection (say to XML) and then reloading it?
We have a requirement to allow the users to save their filter expressions and then re-use them later.
Any help would be appreciated.
Thanks,
Brian
We have a requirement to allow the users to save their filter expressions and then re-use them later.
Any help would be appreciated.
Thanks,
Brian
4 Answers, 1 is accepted
0
Hi Brian,
Currently we do not have such an example, but this forum post can help you.
Each FilterDescriptor has only 5 properties:
string Member
FilterOperator Operator
object Value
Type MemberType
bool IsCaseSensitive
So, you can traverse the filter descriptors tree recursively and store these values in XML. For the CompositeFilterDescriptors that you encounter you should store the LogicalOperator property.
Then do the opposite by reading the XML and reconstructing the tree.
I hope this helps.
Sincerely yours,
Ross
the Telerik team
Currently we do not have such an example, but this forum post can help you.
Each FilterDescriptor has only 5 properties:
string Member
FilterOperator Operator
object Value
Type MemberType
bool IsCaseSensitive
So, you can traverse the filter descriptors tree recursively and store these values in XML. For the CompositeFilterDescriptors that you encounter you should store the LogicalOperator property.
Then do the opposite by reading the XML and reconstructing the tree.
I hope this helps.
Sincerely yours,
Ross
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
Naresh
Top achievements
Rank 1
answered on 10 Sep 2010, 10:17 PM
Ross,
Could you please resend the Forum Post link? The one embedded in your response does not work.
Thank you,
Brian
Could you please resend the Forum Post link? The one embedded in your response does not work.
Thank you,
Brian
0
Hello,
Vlad
the Telerik team
Here is the correct link:
http://www.telerik.com/community/forums/wpf/data-filter/raddatafilter-storage.aspx
Vlad
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
Naresh
Top achievements
Rank 1
answered on 13 Sep 2010, 02:07 PM
Thank you!