从KeyDown事件Winform获取Ascii代码阿拉伯语 [英] Get Ascii Code arabic From KeyDown Event Winform

查看:109
本文介绍了从KeyDown事件Winform获取Ascii代码阿拉伯语的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


如何从KeyDown事件Winform中获取阿拉伯语密钥的Ascii代码

e.KeyValue通常是英文的Ascii代码
请我帮忙.

Hi
how can I get Ascii Code of Arabic key From KeyDown Event Winform

e.KeyValue is often give english Ascii Code
please I need your helps.

推荐答案

"ASCII码阿拉伯语"是oxymoron(请参阅 ^ ],抱歉,我没有找到此维基百科文章的阿拉伯语版本:-)). ASCII是7位代码或8位代码,具有未使用的高位(= 0),因此所有代码点整数值均低于128的值.阿拉伯语受Unicode支持,所有代码点均在BMP中(需要16位) ),代码点范围从0x0600到0x06FF,从0x0075到0x077F进行补充,表示形式从0xFB50到0xFDFD —比ASCII可以容纳更多字符:-).
请参阅 http://www.unicode.org/charts/ [ http://msdn.microsoft.com/en-us/library/system.windows.forms.keyeventargs.keyvalue.aspx [ ^ ],
http://msdn.microsoft.com/en-us/library/system.windows.forms.keyeventargs.keydata.aspx [ ^ ],
http://msdn.microsoft.com/en-us/library/system.windows.forms.control.keydown.aspx [ ^ ].

—SA
"ASCII Code Arabic" is oxymoron (see http://en.wikipedia.org/wiki/Oxymoron[^], sorry, I did not find Arabic version of this Wikipedia article :-)). ASCII is 7-bit code or 8-bit code with unused high bit (=0), so all code points integer values are below the value of 128. Arabic is supported as Unicode, all code points are in BMP (which need 16 bits), code point range from 0x0600 to 0x06FF, supplements from 0x0075 to 0x077F, presentation forms 0xFB50 to 0xFDFD — way more characters then ASCII could fit :-).

Please see http://www.unicode.org/charts/[^].

.NET Framework fully supports .NET, ASCII is not used. You can get the integer value representing the Unicode code point from as System.Windows.Forms.KeyEventArgs.KeyValue property passed to the event handlers of events like System.Windows.Forms.KeyDown/KeyUp.

Please see:
http://msdn.microsoft.com/en-us/library/system.windows.forms.keyeventargs.keyvalue.aspx[^],
http://msdn.microsoft.com/en-us/library/system.windows.forms.keyeventargs.keydata.aspx[^],
http://msdn.microsoft.com/en-us/library/system.windows.forms.control.keydown.aspx[^].

—SA


没有ASCII阿拉伯代码这样的东西. ASCII不包含那些字符,这就是为什么您需要获取Unicode值的原因.我假设传入的其他事件args之一为您提供了?
There is no such thing as an ASCII Arabic code. ASCII does not contain those chars, that''s why you need to get the Unicode value. I assume that one of the other event args passed in gives you that ?


这篇关于从KeyDown事件Winform获取Ascii代码阿拉伯语的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆