Works sometimes -- but not other times

Ken Corey ken at
Fri Jun 22 01:54:04 EDT 2012

Uh...why are you using the on idle handler? Searching and showing a 
picture isn't something you're going to want to do a lot of times, it's 
something that is directly tied to keystrokes...and you're only going to 
want to do it once per keystroke. Also you feel it's causing a race 
condition...and if that is the case it's always best to not code 
yourself into that corner if you can help it.

That said, I'd guess that there's a problem with 'me' not being set to 
what you'd expect in the on idle handler.

But again, why can't this all be done in the keyDown handler? Fill the 
list, check for the end condition, display the photo if needed, done. 
(I'd write some code, but haven't had my coffee yet...:^)

on idle gets called regularly (how regularly is icontrolled by 
idleRate/idleTicks).  Is the list of users going to change in any way 
other than a keystroke?


On 22/06/2012 00:45, Mark Rauterkus wrote:
> I must not be using the right handler. Now deploying, poorly, the "on
> Idle" handler.

More information about the Use-livecode mailing list