Adding numbers

Michael J. Lew michaell at unimelb.edu.au
Tue Dec 11 17:43:00 EST 2001


Sometimes (mostly) I find it best to prevent a non-number input 
rather than complain about it later. Put the following script into a 
field that you want the user to enter a number into:

on keyDown theKey
   if theKey is in "1234567890-." then pass keyDown
end keyDown

-- 
Michael J. Lew

Senior Lecturer
Department of Pharmacology
The University of Melbourne
Parkville 3010
Victoria
Australia

Phone +613 8344 8304

**
New email address: michaell at unimelb.edu.au
**



More information about the use-livecode mailing list