View Full Version : newbie question : when I set the value of a combo, the other options dissapear

25 Feb 2011, 1:47 AM
I have the following combobox :

var queryTypeStore = new Ext.data.ArrayStore({
data: [
['all', 'all'],
['Q', 'Query'],
['R','Reminder Query'],
['E', 'Emergency Query']],
fields: [
{name: 'code'},
{name: 'queryType'}],
listeners: {
load: function(arrayStore, records, options) {
console.log('ca passe');
xtype: 'combo',
id: 'queryType',
name: 'queryType',
hideLabel: true,
store: queryTypeStore,
valueField: 'code',
mode: 'local',
typeAhead: false,
forceSelection: true,
width: 100

When I don't set the value of the combo, I can see all the options displayed

But when I set the value as following :


the other options disappear from the page

Thank you in advance for your answers

25 Feb 2011, 8:34 AM
xtype: 'combo',
triggerAction: 'all', // add this line in your definition
id: 'queryType',
name: 'queryType',

25 Feb 2011, 11:04 AM
Hi laurentParis and thank you for your answer, it works as you said

moreover I don't understand why the values are no more displayed after I have set or selected a value

Thanks again