Kill Messages

dunbarx at dunbarx at
Thu Apr 10 18:01:34 CEST 2014

Most times these things can be solved by rethinking, And I say this having no idea what you were thinking. Try this in the card script:

on arrowKey var
   if  keysDown() = 65363 then
      set the loc of btn 1 to item 1 of the loc of img 1 + 1 & "," & item 2 of the loc of img 1
   end if
end arrowKey

Note this can be done with a rawKeyDown handler just as well.

Craig Newman

-----Original Message-----
From: Ray <ray at>
To: use-livecode <use-livecode at>
Sent: Thu, Apr 10, 2014 11:41 am
Subject: Kill Messages

I've written a handler which nudges a selected image when an arrow key 
is pressed.  The problem is if the user holds the arrow key down for a 
few seconds the messages get backed up.  When the user finally lets the 
arrow key up the object keeps nudging across the screen.

I've tried to stop the nudging with the keysDown() function but not 
having any luck.  I need some way to detect there are no keys down and 
kill any messages which have been backed up.

Ray Horsley
LinkIt! Software

use-livecode mailing list
use-livecode at
Please visit this url to subscribe, unsubscribe and manage your subscription 


More information about the use-livecode mailing list