close the answer dialog from script
paolo mazza
paolo.mazza at neol.it
Fri Aug 24 10:26:07 EDT 2007
Thanks for your help. I tryed to use the command
close stack "Answer Dialog"
Actually it closes the answer dialog but unfortunately the
exit to top
command in the following line does not work and the it does not stop.
See this sample. This script put "2" into message even if I did not press
any button.
Have a good day. Paolo
global TempoIniziale,gTEMPOCONTROL
on mouseUp
put the seconds into TempoIniziale
ControlloTempo
answer "You are great" with "OK" and "Annulla"
if it is "OK" then
put "1" into message
else
put "2" into message
end if
end mouseUp
on ControlloTempo
put the seconds into TEMPO2
-- put TEMPO2 && TempoIniziale & return after message
if (TEMPO2 - TempoIniziale) > 4 then
close stack "Answer Dialog"
exit to top
else
send "ControlloTempo" to me in 2 seconds
put the result into gTEMPOCONTROL
end if
end ControlloTempo
More information about the use-livecode
mailing list