Recent Comments
  1. Re: Onclick event only accessible by a user with edit rights

    Dude, I love you! I just wasted 2 days trying to find the problem. I didn't even notice in the begin...

    --Alex

Force TextField value to uppercase in Extjs

Posted in By Nicholas Lu

We need to force TextField convert any input to uppercase in Extjs. You can enable key events and listen for those:

 

new Ext.form.TextField({
    enableKeyEvents: true,
    style : {textTransform: "uppercase"},
    listeners:{
        change: function(field, newValue, oldValue){
                       field.setValue(newValue.toUpperCase());
                  }
     }
});
    Comments are closed for this post, but if you have spotted an error or have additional info that you think should be in this post, feel free to contact me.