I have a few text boxes on my UI that I want to display the mobile keyboard for when the control has focus, then go away.
Note: for this particular program, it is a tall screen and has no physical keyboard on the device.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Add an InputPanel to your Form, hook up the GotFocus and LostFocus events of the TextBox and show/hide the input panel in the event handlers:
Update
In response to ctacke’s request for completeness; here is sample code for hooking up the event handlers. Normally I would use the designer for this (select the textbox, show the property grid, switch to the event list and have the environment set up handlers for
GotFocusandLostFocus), but if the UI contains more than a few text boxes you may wish to have it more automated.The following class exposes two static methods, AttachGotLostFocusEvents and DetachGotLostFocusEvents; they accept a ControlCollection and two event handlers.
Usage example in a form: