Microsoft KB Archive/265799

= How To Activate the Soft Input Panel (SIP) from an eVB Application =

Article ID: 265799

Article Last Modified on 6/29/2004

-

APPLIES TO


 * Microsoft eMbedded Visual Basic 3.0, when used with:
 * Microsoft Windows CE Platform Software Development Kit for Handheld PC 2000

-



This article was previously published under Q265799



SUMMARY
This article illustrates how to call the SipShowIM function to activate the virtual keyboard on a Pocket PC device from an eMbedded Visual Basic (eVB) application.



Step-by-Step Example
 Start a new PocketPC Project in eMbedded Visual Basic. Form1 is created by default. Place two command buttons on Form1. Do not be concerned about the placement of the controls.  Paste the following code into Form1: Option Explicit Declare Function SipShowIM Lib &quot;coredll&quot; (ByVal flags As Long) As Long

Private Sub Form_Load Command1.Move 240, 120, 3015, 495 Command2.Move 240, 720, 3015, 495 Command1.Caption = &quot;Show Keyboard&quot; Command2.Caption = &quot;Hide Keyboard&quot; Form1.Caption = &quot;SipShowIM Sample&quot; End Sub

Private Function Showkeyboard As Long Showkeyboard = SipShowIM(1) End Function

Private Function Hidekeyboard As Long Hidekeyboard = SipShowIM(0) End Function

Private Sub Command1_Click Showkeyboard End Sub

Private Sub Command2_Click Hidekeyboard End Sub

Private Sub Form_OKClick App.End End Sub  In the Project Properties dialog box, set the Run on Target option to Pocket PC (default device). Press the F5 key to run the project, and click the buttons to show and hide the virtual keyboard.

NOTE: This sample runs only on the device and not in the emulator.

