PDA

View Full Version : Where's displayField property in combo box?



jackygurui
27 Mar 2010, 3:54 AM
I can't find the displayField property in the combo box property window, also fieldLabel isn't there either.

jackygurui
27 Mar 2010, 3:55 AM
Also how can I add a templet to the combo box?

firefoxSafari
27 Mar 2010, 10:19 AM
I'm not sure about the template or the displayField. I can see the fieldLabel, though. It's a property on the layout, so the combo has to be a direct child of some container with layout of 'form'.

dboyne
28 Mar 2010, 10:49 PM
I also would like to know how you set the display and value fields for a combo box

jackygurui
29 Mar 2010, 11:12 AM
I copied the following code from the docs.


var combo = new Ext.form.ComboBox({
typeAhead: true,
triggerAction: 'all',
lazyRender:true,
mode: 'local',
store: new Ext.data.ArrayStore({
id: 0,
fields: [
'myId',
'displayText'
],
data: [[1, 'item1'], [2, 'item2']]
}),
valueField: 'myId',
displayField: 'displayText'
});


There are 7 configurations used by the example, and only 3 can be found in the config window! I've lost count on how many of them from the api that aren't in the config window. How do we suppose to learn and use the designer if it can't even support the example from docs?