我有一个ASPxGridView组件,从SQL查询填充我想在我的ASPX Gridview上应用过滤器,所以我写道:
<dx:ASPxGridView runat="server" ID="gvExecReq" Visible="false" AutoGenerateColumns="true"
OnPageIndexChanged="gvExecReq_PageIndexChanged" OnBeforeColumnSortingGrouping="gvExecReq_BeforeColumnSortingGrouping">
**<Settings ShowFilterRow="True" />
<Settings ShowFilterBar="Visible" ShowHeaderFilterButton="True" />**
</dx:ASPxGridView>
过滤器已经建立,但它不起作用我需要添加更多?
请使用以下设置以使过滤器运行:
<Settings ShowHeaderFilterButton="true"
EnableFilterControlPopupMenuScrolling="True"
ShowFilterBar="Visible" ShowFilterRow="True" ShowFilterRowMenu="True" />
也可以在网格的列中控制过滤的条件,即包含,等于,不包含等。
<dx:GridViewDataColumn Settings-AutoFilterCondition="Contains" Settings-FilterMode="DisplayText">
如果在数据库文件类型是string
你可以写一部分文本进行搜索,但是类型为int
或decimal
等,你应该写所有文本,即使它可以找到行