-
C# using DevExpress.Data.Filtering; //... private void FindBySubjectAction_Execute(object sender, ParametrizedActionExecuteEventArgs e) { IObjectSpace objectSpace = Application.CreateObjectSpace(); string paramValue = e.ParameterCurrentValue as string; if(!string.IsNullOrEmpty(paramValue)) { paramValue = "%" + paramValue + "%"; } object obj = objectSpace.FindObject(((ListView)View).ObjectTypeInfo.Type, new BinaryOperator("Subject", paramValue, BinaryOperatorType.Like)); if(obj != null) { e.ShowViewParameters.CreatedView = Application.CreateDetailView(objectSpace, obj); } }
XAF添加Action到菜单 用于过滤
最新推荐文章于 2022-03-10 09:50:56 发布