PDA

View Full Version : select change event



eyepoker
1 Jul 2011, 4:43 PM
I'm not having any luck getting the change event to fire in his example:



var stepTwoSelect_noe = new Ext.form.Select({
options: [
{text:'Select One...',value:''},
{text:'1',value:'1'},
{text:'2',value:'2'},
{text:'3',value:'3'},
{text:'4',value:'4'},
{text:'5',value:'5'}
],
listeners:{
change:{
element: 'el',
fn: function(arg,val){console.log('it works!! arg= ' + arg + ', val= ' + val);}
}
}
});


I tried select for the event but it doesn't work either and the docs say thats deprecated anyway...

eyepoker
3 Jul 2011, 1:30 PM
I found the answer at the bottom of this thread:

http://www.sencha.com/forum/showthread.php?116669-Noob-Change-listener-on-Input-element-how-to-get-value

I've watched the video tuts on listeners, read the docs... I've seen no documentation on what the guy in the above thread did. So..... if not the api docs where should I be looking...?