How to display number of characters in text field while typing in client side

I need to display the number of characters typed in a text field while typing each character from the client side. Now i am displaying it in the TextChanged event. But i think that runs from the server side and it take a bit time after each character is typed. So i need to show it fast, if it is run from client side

That would have to be written in JavaScript.
See
http://www.w3schools.com/jsref/event_onkeyup.asp
http://www.w3schools.com/tags/att_input_value.asp
http://www.w3schools.com/jsref/jsref_length_string.asp
http://www.w3schools.com/jsref/prop_html_innerhtml.asp

But how do i convert that to xojo code

Once the JavaScript program is complete, use http://documentation.xojo.com/index.php/WebControl.ExecuteJavaScript

To avoid the back and forth to the server you can’t, it will have to be in JavaScript.