Deja Vu

Kay C Lan lan.kc.macmail at gmail.com
Fri Mar 21 02:08:41 EDT 2014


On Fri, Mar 21, 2014 at 11:53 AM, Bob Sneidar
<bobsneidar at iotecdigital.com>wrote:

> I know this has come up in the past, because I remember the poor fellow
> who was struggling with it.
>
> I have a field with a closeField handler. In the handler there is an
> answer dialog command which the user must respond to.
>

Sorry I don't know how to put links do old posts, but if you search for
"What's is wrong with this Script logic" you'll find a work around.
Basically something like this:

on closefield
  send "hCheckEntry me" to me in 1
end closefield

on hCheckEntry pData
  repeat until pData is an integer
    if the shiftkey is down then exit to top
    ask warning "Please enter only whole numbers!" with pData \
          titled "Enter A Number"

    if the result = "cancel" then exit to top
    put it into pData
  end repeat
  put pData into me
end hCheckEntry



More information about the use-livecode mailing list