javascript - ExtJs - Change Textfield VType dynamically -


a rather straightforward question. no answer found anywhere.

using extjs 4.2

i have 2 custom vtypes, , 1 textfield. want change textfield's vtype when user clicks radio button.

i know text field has been created doing:

textfield.vtype = 'othertype'; 

won't me. neither will:

ext.apply(textfield,{vtype:'othertype'});   

so obvious stuff out. i'm toying destroying , re-creating it, (if works) seems overkill.

using ext.apply worked me, fiddle here: https://fiddle.sencha.com/#fiddle/4d4

hope helps..


Comments

Popular posts from this blog

rest - Spring boot: Request method 'PUT' not supported -

java - WrongTypeOfReturnValue exception thrown when unit testing using mockito -

symfony - imagine_filter() not generating the correct url in LiipImagineBundle -