开发者

How to set the Windows Mobile 6 IME mode (to numbers only)

In Windows Mobile 5 one of the following methods works to set an input to numbers only:

// Managed InputModeEditor.SetInputMode(textBox, InputMode.Numeric);

// Native Wrapper InputModeSupport.SHSetImeMode(textBox.Handle, InputModeSupport.SHIME_MODE.SHIME_MODE_NUMBERS);

In Windows Mobile 6, neither works.

How do you set the IME to "Numbers Only" in WM 6.0 / .NET CF 3开发者_如何学Python.5?


To set IME mode you can use the two methods above, switching based on platform using the SystemSettings class to inform it. If you want to use the SIP instead, you can find the GUID of the WYSIWYG keyboard, or "guess" by enumerating all SIPs and choosing one with "Numeric" in its name. Ultimately though, there is no way to guarantee the numbers only keyboard in code.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜