Is it possible to "emulate" the keystroke Win+R (or more generally speaking: any combination with Win key) with an ASCII code?

It is possible to send Ctrl+Something as an ASCII code, so I wonder whether it can be expanded on other keys (like Win).


  • 2
    What problem are you trying to solve precisely? Knowing what your actual problem is, might prevent this question, from being closed or down voted into oblivion. – Ramhound Dec 2 '15 at 15:07
  • 2
    AFAIK, win, shift, ctrl and alt are usually referred to as "virtual key states." Programs (or the OS libraries) will receive the "normal keys" and then check the key states and then {do magic}. So you cannot send an ascii code, you want to "emulate keystrokes" using, e.g. SendKeys() – Yorik Dec 2 '15 at 15:14
  • There is no ASCII code for the Windows key. See this answer on SO – Burgi Dec 3 '15 at 16:05

No. ASCII code represents a single character. What you are asking for is a key combination, not a character. The only way you can send a key combination like in your example is if that key combination represents a character. I.E. if Ctrl + 4 produced a character then ASCII code would represent that character but something, like software, would still need to convert the character back to a key stroke.

  • Obviously this is not true. First 31 codes are not characters. That's why we speak about ASCII codes table, not ASCII characters table. First 31 codes are emulated in many cases by key (e.g. ASCII#9 = TAB or ASCII#27 = ESC) or key combination (e.g. ASCII#3 = ETX, represented on Unix as Ctrl+C). That's why I asked whether there is any way to map/emulate Win key by ASCII code. – boleslaw.smialy Dec 4 '15 at 9:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.