views:

101

answers:

3

Hello,

Can anybody please tell me e.which codes for key press CTRL + A and CTRL + E.

Also please tell me where i can find these values, i tried searching google but no appropriate results and i dont want shortcuts plugin for simple needs.

Thank You.

A: 

Is this helpful?

http://www.scottklarr.com/topic/126/how-to-create-ctrl-key-shortcuts-in-javascript/

If 'S' is 83, then A = 65, right? And E=69?

Victor
according to me the keycodes are different, if i am wrong please rectify me.
Shishant
E=68, seems like I can't count :P
Victor
@Victor- E=69, your A is just off. you can always refer to an ascii table for verfication
TStamper
Ah... yes, I can't count
Victor
A: 

In jQuery UI Core (ui.core.js) you have translations for common key codes.

$.keyCode = { 
    ...
    ENTER: 13, 
    ...
};

just check there the key codes, you don't have to include this file.

TTT
+1  A: 

Take a look at Ctrl + Key Combination simple example:

if(e.keyCode == key.charCodeAt(0) && isCtrl)
TStamper
for keycodes you can look at an Ascii table: http://www.asciitable.com/
TStamper