InputModeEditor.SetInputMode Method
Specifies the input mode on a Smartphone.
Namespace: Microsoft.WindowsCE.Forms
Assembly: Microsoft.WindowsCE.Forms (in microsoft.windowsce.forms.dll)
Syntax
'Declaration
Public Shared Sub SetInputMode ( _
control As Control, _
mode As InputMode _
)
'Usage
Dim control As Control
Dim mode As InputMode
InputModeEditor.SetInputMode(control, mode)
public static void SetInputMode (
Control control,
InputMode mode
)
public:
static void SetInputMode (
Control^ control,
InputMode mode
)
public static void SetInputMode (
Control control,
InputMode mode
)
public static function SetInputMode (
control : Control,
mode : InputMode
)
Parameters
- control
A TextBox control.
- mode
One of the InputMode values.
Remarks
You can set the input mode only on a TextBox.
Example
The following code example sets a text box to have a numeric input mode. This code example is part of a larger example provided for the InputModeEditor class.
' Set input mode for phone number text box to Numeric.
InputModeEditor.SetInputMode(textBox2, InputMode.Numeric)
// Set input mode for phone number text box to Numeric.
InputModeEditor.SetInputMode(textBox2, InputMode.Numeric);
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see .
Platforms
Windows Mobile for Smartphone
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see System Requirements.
Version Information
.NET Compact Framework
Supported in: 2.0
See Also
Reference
InputModeEditor Class
InputModeEditor Members
Microsoft.WindowsCE.Forms Namespace