EXT.Net自定义搜索组合框触发用户命中ENTER
问题描述:
是否有任何示例方式来告诉Ext.NET组合框显示用户命中输入自动完成可用值。
I really like advanced search sample of Ext.net combo box sample .在我的自定义中,我从SQL中进行数据存储,并且为了搜索而进行查询非常繁琐,以至于无法自动触发结果集。 我的想法是允许用户输入查询字符串,并按Enter或任何热键,然后做逻辑从sql获取数据,并允许用户选择显示网格中的可用项目?EXT.Net自定义搜索组合框触发用户命中ENTER
我的环境是.NET4,ASP.NET,WebForms的,Ext.Net V2
答
Our colleges from Ext.Net helped me to solve problem
<ext:ComboBox
runat="server"
DisplayField="Common"
ValueField="Common"
TypeAhead="false"
Width="570"
PageSize="10"
HideBaseTrigger="true"
MinChars="10000"
TriggerAction="Query">
...
<Listeners>
<SpecialKey Handler="
if (e.getKey() == e.ENTER) {
this.doQuery(this.getValue(), true);
}"></SpecialKey>
</Listeners>
</ext:ComboBox>