i have created project(classic) mobile web using titanium. have created textfield.
var txtfield = ti.ui.createtextfield({ id:"txtid", value:"txtvalue"});
i have added event "change".
txtfield.addeventlistener('change', function(e){alert("change event fired");});
after when trying change value programmatically
txtfield.value = "someothet text"
the change event not triggered. can 1 please me regarding this.
thanks in advance, swathi.
as far know fire "change" event when modified in user interface. , have means of changing value without firing "change" event ;-)
you write have created wrapper class. should create "setter" function (e.g. "set" or "setvalue") in wrapper class set value. within setter set value , fire change event. way have maintain change logic in 1 place.
hth
/john
Comments
Post a Comment