What is wrong with this Script logic?

Robert Brenstein rjb at robelko.com
Fri Jan 11 09:50:48 EST 2013


On 11.01.2013 at 11:04 Uhr +0800 Kay C Lan apparently wrote:
>If I turn Debug Mode OFF, and repeat the above, after I enter B in my
>ask Dialog I get the IDE Errors widow come up with:
>
>Type: Handler: can't find handler
>Object: fldTest
>Line: hCheckEntry tAnswer
>Hint: hCheckEntry
>
>My Ask Dialog Box is also presented with B as the default. If I press
>"Cancel" my ask Dialog comes back with "ask warning" as the default
>answer. If I press 'Cancel' again, it finally cancels.
>
>So why is my script having a recursion problem or not finding the handler?
>

I would guess that at the time the script calls hCheckEntry second 
time, the dialog stack still has the focus and this the handler is 
not found. May be moving it to the stack level or background script 
is a cure.

Robert




More information about the use-livecode mailing list