문제

I use KendoNumericTextBox to read real numbers.

When keyboar switched to russian, i cann't enter russian ',' or '.'(english key '/' or '?') but can enter 'б' or 'ю' (english key ',' or '.')

<script src="http://cdn.kendostatic.com/<version>/js/cultures/kendo.culture.en-GB.min.js"></script>

<input id="numeric" type="number" value="17" min="0" max="100" step="1" />

<script type="text/javascript">
kendo.culture("ru-RU");
$("#numeric").kendoNumericTextBox();
</script>
도움이 되었습니까?

해결책

After day of search:

It's bug of framework. It check key in onkeypress event and allow only 188 or 190 key ('.' and ','). But on russian keyboard it is 'б' and 'ю' key. Comma and dot is on 191 and 191+shift keis.

For resolve it I change onkeydown method to allow 191 key too and add onkeypress method to forbid {'б','ю','Б','Ю','/','?'}

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top