0

我们需要在 Syncfusion 的 WPF 网格中保留过滤器(标题行上的漏斗过滤器)。

如何读取当前的过滤器设置以便我们可以持久保存它?以编程方式恢复这些过滤器的方法是什么?

这甚至可能吗?

谢谢,汤姆

4

1 回答 1

0
You can get the Filters for particular column by using the following code snippet.

Code snippet[C#]:

var Filters = this.SyncGrid.VisibleColumns["CustomerID"].Filters;


And also you can add the Filters for particular column by using the following code snippet.

Code Snippet[C#]:
this.SyncGrid.VisibleColumns["CustomerID"].Filters.Add(new Syncfusion.Windows.Data.FilterPredicate()
{
    FilterValue = 2,
    PredicateType = Syncfusion.Windows.Data.PredicateType.Or,
    FilterBehavior = Syncfusion.Linq.FilterBehavior.StringTyped,
    FilterType = Syncfusion.Linq.FilterType.Equals
});


Note: Here CustomerID is the MappingName of GridDataVisibleColumn
于 2013-05-09T05:16:45.487 回答