In the script of fld "text"...

on keyDown theKey
   if the number of chars of fld "text" > 0 then
      beep
      exit keyDown
   else
      put theKey into fld "text"
   end if
end keyDown

> Hi there,
> 
> I limit text entry of fld "text" with following code.
> 
> on keyDown pKey
>    if (the formattedHeight of fld "text" < the height of fld "text")
>   then
>   pass keyDown
>   end if
> end keyDown
> 
> One thing that I want to change now is a way to force a key to enter
> just one character after being pressed/hold down.
> Any thoughts on that?
> 
> greetings,
> 
> William

                                          
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to