Jump to content

Virtual-Key Codes

The following table shows the symbolic constant names, decimal values, and mouse or keyboard equivalents for the virtual-key codes used by the system.

Key ID Mouse or keyboard equivalent
鼠标或键盘
317 Left mouse button (mouse1)
鼠标左键 (mouse1)
318 Right mouse button (mouse2)
鼠标右键 (mouse2)
319 Middle mouse button (mouse3)
鼠标中键 (mouse3)
320 Side mouse button (mouse4)
鼠标侧键 (mouse4)
321 Side mouse button (mouse5)
鼠标侧键 (mouse5)


80 SHIFT key
82 ALT key
84 CTRL key


1 KEY_0
2 KEY_1
3 KEY_2
4 KEY_3
5 KEY_4
6 KEY_5
7 KEY_6
8 KEY_7
9 KEY_8
10 KEY_9


11 KEY_A
12 KEY_B
13 KEY_C
14 KEY_D
15 KEY_E
16 KEY_F
17 KEY_G
18 KEY_H
19 KEY_I
20 KEY_J
21 KEY_K
22 KEY_L
23 KEY_M
24 KEY_N
25 KEY_O
26 KEY_P
27 KEY_Q
28 KEY_R
29 KEY_S
30 KEY_T
31 KEY_U
32 KEY_V
33 KEY_W
34 KEY_X
35 KEY_Y
36 KEY_Z


37 KEY_PAD_0
38 KEY_PAD_1
39 KEY_PAD_2
40 KEY_PAD_3
41 KEY_PAD_4
42 KEY_PAD_5
43 KEY_PAD_6
44 KEY_PAD_7
45 KEY_PAD_8
46 KEY_PAD_9
47 KEY_PAD_DIVIDE
48 KEY_PAD_MULTIPLY
49 KEY_PAD_MINUS
50 KEY_PAD_PLUS
51 KEY_PAD_ENTER
52 KEY_PAD_DECIMAL


66 KEY_SPACE
68 KEY_TAB
69 KEY_CAPSLOCK
70 KEY_NUMLOCK
71 KEY_ESCAPE
72 KEY_SCROLLLOCK
73 KEY_INSERT
74 KEY_DELETE
75 KEY_HOME
76 KEY_END
77 KEY_PAGEUP
78 KEY_PAGEDOWN
79 KEY_BREAK


89 KEY_UP
90 KEY_LEFT
91 KEY_DOWN
92 KEY_RIGHT


93 KEY_F1
94 KEY_F2
95 KEY_F3
96 KEY_F4
97 KEY_F5
98 KEY_F6
99 KEY_F7
100 KEY_F8
101 KEY_F9
102 KEY_F10
103 KEY_F11
104 KEY_F12
  No Result!
×
×
  • Create New...