Type-ahead is a popular feature of the ComboBox
class. In this recipe's example, after typing the first characters of the car make in the Make combo box, the component completes the word and shows a number of suggestions, as shown below:
var makes=[['Acura'], ['Aston Martin'], ['Audi'], ['BMW'], ['Buick'], ['Cadillac'], ['Chevrolet'], ['Chrysler'], ['Dodge'], ['Ferrari'], ['Ford'], ['GMC'], ['Honda'], ['HUMMER'], ['Hyundai'], ['Infiniti'], ['Isuzu'], ['Jaguar'] ]
var makesStore=new Ext.data.SimpleStore({ fields: ['name'], data:makes });
3. Declare the combo box:
var makesCombo={ xtype:'combo', store: makesStore, displayField: 'name', valueField: 'name', typeAhead: true, editable: true, mode: 'local', forceSelection: true, triggerAction: 'all', fieldLabel: 'Make', emptyText: 'Select a make...', selectOnFocus: true }
4. Create a form to host the combo box:
Ext.onReady(function() { var newCarForm...