你传递的参数是错的,首先按照文档写,不行再考虑其他问题:
lParam
The repeat count, scan code, extended key flag, context code, previous key state flag, and transition state flag, with values as defined below.
Table 1
Bit
Meaning
0-15
Repeat count. Since the first byte and second byte are continuous, this is always 1.
16-23
Scan code for a complete Asian character.
24
Extended key.
25-28
Not used.
29
Context code.
30
Previous key state.
31
Transition state.