Return to Snippet

Revision: 36713
at December 4, 2010 01:03 by feeorin


Updated Code
/* Use this function to be dispatch from an Event.CHANGE on a textfield */

private function _handleChangeText ($evt:Event):void {
			
	var $curInput:String = evt.target.text;
	evt.target.text = $curInput.toLocaleUpperCase();
			
}

Revision: 36712
at November 25, 2010 06:39 by feeorin


Initial Code
/* Use this function to be dispatch from an Event.CHANGE on a textfield */

private function _handleChangeText ($evt:Event):void {
			
	var $curInput:String = $evt.target.text;
	$evt.target.text = "";
	$evt.target.text = $curInput.toLocaleUpperCase();
        $evt.target.setSelection (inputTextField.length, inputTextField.length);
			
}

Initial URL

                                

Initial Description

                                

Initial Title
Force text input to uppercase

Initial Tags
text

Initial Language
ActionScript 3