We do this by simply adding an event listener in our component for keydown.
Then we interrogate the key.  In your case you would need to check if the
keyCode is 1 and that event.ctrlKey == true.  If that happens then call
whatever function you need to call.  Not sure if you are looking for
anything more complex, but this very simple logic works great for us.

Dale

-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Laurence
MacNeill
Sent: Friday, April 17, 2009 3:16 AM
To: [email protected]
Subject: [AFFUG Discuss] Key bindings...

Is there a way to bind a key to a button on a form?  So that any time you
hit that key (say something you wouldn't ordinarily type, like
Ctrl-1 or something) it'll act like you just clicked on that button?

Thanks,

Laurence MacNeill
Mableton, Georgia, USA


END IRS TYRANNY NOW:
http://www.fairtax.org/

SHUT DOWN THE FEDERAL RESERVE SYSTEM:
http://www.freedomtofascism.com/





-------------------------------------------------------------
To unsubscribe from this list, simply email the list with unsubscribe in the
subject line

For more info, see http://www.affug.com
Archive @ http://www.mail-archive.com/discussion%40affug.com/
List hosted by http://www.fusionlink.com
-------------------------------------------------------------



-------------------------------------------------------------
To unsubscribe from this list, simply email the list with unsubscribe in the 
subject line

For more info, see http://www.affug.com
Archive @ http://www.mail-archive.com/discussion%40affug.com/
List hosted by http://www.fusionlink.com
-------------------------------------------------------------


Reply via email to