Blocking returns in a locked text field

Ken Ray kray at sonsothunder.com
Sun May 22 08:17:02 EDT 2011


> Earlier I thought I had a solution for this, but I'm not happy with what I've
> come up with. Anyone have a simpler/better solution?

You want to block returns in a *locked* text field? How is the user able to
enter a return when the field is locked?

Regardless, though, you can simply add this to your field:

on returnInField
end returnInField

on enterInField
end enterInField

If the field is unlocked (or locked but has the focus), then this will
prevent returns from being processed by the field.

Ken Ray
Sons of Thunder Software, Inc.
Email: kray at sonsothunder.com
Web Site: http://www.sonsothunder.com/






More information about the use-livecode mailing list