Reputation: 2449
Here is my code -
Store = new Ext.data.JsonStore({
url: 'url',
totalProperty: 'count',
id: 'Code',
root: 'rows',
autoLoad: true,
triggerAction: 'all',
fields: ['title', 'description'],
listeners: {
load: {
fn: function (store) {
Ext.getCmp('Combo').setValue(store.getAt('1').get('title'));
Ext.getCmp('Combo').fireEvent('select');
}
}
}
}
);
xtype: 'combo',
id: 'Combo',
store: Store,
fieldLabel: 'title',
displayField: 'title',
valueField: 'title',
typeAhead: false,
editable: false,
allowBlank: false,
mode: 'local',
emptyText: 'Select...',
forceSelection: true,
triggerAction: 'all',
name: 'DefaultCombo',
selectOnFocus: true,
width: 150
, onSelect: function () {
alert('message');
}
Combobox value is being set here, but onSelect
is not firing here.
I am using 3.4 version
Upvotes: 1
Views: 3128