PDA

View Full Version : How to load gridcombobox with dynamic datastore correctly?



joza
9 Aug 2011, 10:51 PM
I am working on a simple grid form which has a combobox and datasource as proxy (like http://goo.gl/2fxP8). The combobox loads properly but when i try to select one of the list items the gridform closes and combobox doesn't close. Can anyone help me out ?

I am planning to extend the combobox onselect function as well so that once the list item is chosen other fields will be loaded dynamically.



searchField = new Ext.form.ComboBox({
store: ds,
name : 'search',
id:'search',
fieldLabel : 'Search',
displayField:'title',
typeAhead: false,
loadingText: 'Searching...',
pageSize:10,
minChars:2,
triggerAction: 'all',
width: 200,
tpl: resTpl,
itemSelector: 'div.search-item',
onSelect: function(record){
/* Set Values to other fields here */
}
}),