Allow uppercase only in a field

Scott Rossi scott at
Tue May 9 04:00:46 EDT 2006

Recently, Sarah Reichelt wrote:

> I have a field where users can type, but I only allow some letters &
> symbols through and then I want them all to be uppercase, although I
> want to allow the users to be able to type in lower case.
> I have the restricted characters working fine in a keyDown handler,
> and I have the field changing to upper case in the keyUp handler, but
> I still see the lower case letter briefly before it changes.
> What I REALLY want is to change the keyDown parameter as I pass it.
> Has anyone already solved this problem?

If I understand you correctly, I'm pretty sure most folks do this by
intercepting the keystrokes *before* they get to the field. So you would
parse/manage the keys you want to allow in variables and them dump the
"formatted" character/s into the field.  Could this work?


Scott Rossi
Creative Director
Tactile Media, Multimedia & Design
E: scott at

More information about the Use-livecode mailing list