c# - Can I determine whether a Ctrl key press is Left Ctrl or Right Ctrl? -


I want to determine whether the Ctrl key is left Ctrl or the right Ctrl key when it is pressed How can I do this?

AFAIK You can not access this information from .net.

However, if you have a specific key currently down, you can use Win32 API to test it, and it can distinguish left and right ctrl key (If you are writing games, you are more likely to work better than the KidAidan handler, because GetAsyncKeyState tests whether the key is in "now", even if it is pressed on "sometime in the past" Gaga, which gives much better accountability ).


Comments

Popular posts from this blog

windows - Heroku throws SQLITE3 Read only exception -

lex - Building a lexical Analyzer in Java -

python - rename keys in a dictionary -