I have a number field and a list in Sencha Touch. When I click on an item in the list, I make an AJAX request to send data to the server. However, if there is data in the number field, I want to clear it when the list is clicked.
I have no problem with this (I set the value to an empty string), however the change event is fired on the number field. This raises another AJAX request that is not needed. Is there a way to clear the number field without involving the change event? SuspendEvents does not work because an event is required to clear the number field.
Any thoughts or suggestions? Thanks!
Code lines I tried:
suspendEvents(); me.getWhatScreen().down('numberfield[name=caseNumber]').setValue(''); resumeEvents(true);
me.suspendEvents(); me.getWhatScreen().down('numberfield[name=caseNumber]').setValue(''); me.resumeEvents(true);
bnrq
source share