I
I
Ilya2013-12-28 17:27:44
Keyboard
Ilya, 2013-12-28 17:27:44

How to get key name from ASCII code?

For example, knowing the code - 13, show that the Enter key.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
M
Maxim Nikitenko, 2013-12-28
@sets88

There is a table here: ASCII in the "Encoding" section, vertically the first digit horizontally the second, for example 31 is "1"
you can also do this in the Linux console:
Display "1"
So using the python 2 language:
Using PHP:
Or here is the service which can do this:
www.branah.com/ascii-converter

V
Vitaly Arkhipov, 2013-12-29
@arvitaly

It seems to me that you can try to use the data of the winuser.h header file, key codes with the VK_ prefix and translate into Russian, although I may be complicating it.

M
Mikhail Andreev, 2014-01-05
@Mikant

oh monsieur! there is nothing easier:

int val = 13;
var key = (System.Windows.Forms.Keys)val;
string str  = key.ToString();

but why?)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question