Custom search trigered by hotkey

  1. #1

    Custom search trigered by hotkey

    Is there any sample way to tell Ext.NET combo box to show auto-complete available values on user hit enter.
    I really like advanced search sample of Ext.net combo box sample . In my customization I do data store from SQL and query for searching is pretty heavy ill love to try avoid auto triggering of result set. My idea is to allow user to type in query string and hit enter or any hot-key and then to do logic of getting data from sql and allowing user to select available items in showed grid?

    May I set combobox or store to do query on users interact not on tayping.



    My environment is .net4, ASP.NET, WebForms, Ext.Net V2
  2. #2
    Hello!

    You can set very high MinChars value and do query manually using SpecialKey handler and doQuery method:

    <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>
  3. #3

    That is that

    Thanx a lot, works like charm.

    Quote Originally Posted by Baidaly View Post
    Hello!

    You can set very high MinChars value and do query manually using SpecialKey handler and doQuery method:

    <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>

Similar Threads

  1. Custom Search
    By DanielU in forum 1.x Help
    Replies: 23
    Last Post: Mar 04, 2013, 10:54 AM
  2. custom search in combobox
    By aditya.murthy88@gmail.com in forum 1.x Help
    Replies: 0
    Last Post: Feb 05, 2011, 8:57 AM
  3. Custom Search on TextArea
    By mj.daly in forum 1.x Help
    Replies: 2
    Last Post: Feb 02, 2010, 9:37 AM
  4. Custom Search
    By sharif in forum 1.x Help
    Replies: 0
    Last Post: Jul 14, 2009, 4:04 PM
  5. Hotkey to display DateField's Calendar
    By leonardobag in forum Examples and Extras
    Replies: 0
    Last Post: Jul 03, 2009, 11:28 AM

Tags for this Thread

Posting Permissions