I know a really good way to do this but it will require a
modification to your hardware.
You just wire up the 000 key to an electric shock generator which
increases in voltage the more times it is pressed. Should do the
trick nicely!
All the Best
Dave
On 7 Mar 2007, at 18:00, Peter
I'd like to do the following. If 000 is typed at superhuman speed, only the
first 0 should make it into a field. But if 000 is typed at normal human
rates, all three should.
Can you think of any way to do this?
The problem is a keypad with a 000 key right next to the 0 key. All it does
is
Try trapping the 'rawkey down' code for the '000' and see if you can just
substitute the '0'
Jim Ault
Las Vegas
On 3/7/07 10:00 AM, Peter Alcibiades [EMAIL PROTECTED]
wrote:
I'd like to do the following. If 000 is typed at superhuman speed, only the
first 0 should make it into a field. But
Peter,
I don't think that is wise. What if the user intentionally pressed
the 000 key. I know people that really use that key, specially people
dealing with money. If they really press 000 and end up with a single
0, they will me pissed.
Andre
On Mar 7, 2007, at 3:10 PM, Jim Ault wrote:
On Wednesday 07 March 2007 18:10, Jim Ault wrote:
Try trapping the 'rawkey down' code for the '000' and see if you can just
substitute the '0'
This is my problem, I can't figure how to do this. Because I've used xev to
find the keycodes, and what is happening is, 0 sends 90, and 000 sends 90
trap the keystrokes, then set a global, test the new ticks...
global mm
on rawKeyDown whichKey
get the ticks - gTicksLastGoodKey
if it gMinKeyDelay -- too short, don't pass the keystroke
else
put the ticks into gTicksLastGoodKey
pass rawkeydown
end if
end rawkd
Jim Ault
Las Vegas
On 3/7/07
Why not glue the key firmly in place? And draw an 'N' just before the
first '0'...
Cheers,
Luis.
On 7 Mar 2007, at 20:44, Jim Ault wrote:
trap the keystrokes, then set a global, test the new ticks...
global mm
on rawKeyDown whichKey
get the ticks - gTicksLastGoodKey
if it gMinKeyDelay
Here's another option which doesn't worry about try to figure out what the
right time is. All it does it checks to see if you are trying to type 0 more
than once. In this case it will beep if you press the '000' key or press '0'
more than once.
---
local lMyDuplicate
ON rawKeyDown theNumber
Ooops. forgot to mention that on my Mac the 0 rawKeyDown code is 48. I don't
know why this should be different on different platforms but you allow for
that with these simple amendments.
---
local lMyDuplicate
ON rawKeyDown theNumber
SWITCH
CASE ((theNumber = 48) AND (lMyDuplicate =
Sorry, pressed the wrong key. Here is the full script:
--
local lMyDuplicate
ON rawKeyDown theNumber
SWITCH
CASE ((theNumber = 48) AND (lMyDuplicate = 0))
CASE ((theNumber = 90) AND (lMyDuplicate = 0))
put 1 into lMyDuplicate
pass rawKeydown
break
CASE ((theNumber = 48) AND
Many thanks guys - I'll have a try with these! And yes, if all else fails
there is always a dab of epoxy...
Peter
On Wednesday 07 March 2007 20:44, Jim Ault wrote:
trap the keystrokes, then set a global, test the new ticks...
global mm
on rawKeyDown whichKey
get the ticks -
11 matches
Mail list logo