|
|
|
Accept Only Alpha-Numeric Characters
Added on 7/8/1999
|
This behavior will restrict input of a field to specific keys.
--Copyright 1999 Chuck Neal
--chuck@mediamacros.com
--If you find this code helpful, send me an e-mail and let me know. :-)
property spriteNum, letters
on keyDown me
if (letters contains the key) then
pass
else
beep
end if
end
on getPropertyDescriptionList me
p_list = [#letters : [#format : #string, #default : "abcdefghijklmnopqrstuvwxyz1234567890-", #comment : "Allowed characters:"]]
return p_list
end
on getbehaviorDescription me
return "This behavior will restrict input of a field to specific keys."
end
|
|