Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hide TabTips

Status
Not open for further replies.

AlastairP

Technical User
Feb 8, 2011
286
AU
TabTip.exe is the on-screen keyboard used in Windows 8 tablet PC

I would like to hide the keyboard with VFP after being used
Can anyone help with this?

 
How do you call it? If you simply RUN /N or ! /N tabtip.exe that keyboard runs. The user can close it.
You gain control on a process you start, when using CreateProcess() Windows API.

Read here:
If you neither call WaitForSingleObject(), nor close the process handle via CloseHandle(), you can terminate the process via TerminateProcess(), after that you should CloseHandle() additionally.
See for the declaration.

Bye, Olaf.
 
The tablet will be used for asset management by field technicians and therefore I am trying to minimize the number of actions required to perform the tasks. Opening and closing of the keyboard automatically at specific moments will greatly improve the operation of the app.

I am currently opening and closing the keyboard with these functions

OPEN
Code:
DECLARE INTEGER ShellExecute IN shell32;
    INTEGER hwnd, STRING lpOperation,;
    STRING lpFile, STRING lpParameters,;
    STRING lpDirectory, INTEGER nShowCmd

ShellExecute (0, "open", "tabtip.exe", "", "", 0)

CLOSE
Code:
FUNCTION closetabletkeyboard
lcProcess="tabtip.exe"
lcComputer = "."
loWMIService = Getobject("winmgmts:" ;
    + "{impersonationLevel=impersonate}!\\" + lcComputer + "\root\cimv2")
colProcessList = loWMIService.ExecQuery ;
    ("Select * from Win32_Process")
For Each loProcess In colProcessList
   IF ALLTRIM(UPPER(loProcess.name)) == ALLTRIM(UPPER(lcProcess))
     loProcess.terminate()
   endif
Next
When running the shell execute, the keyboard appears OK
Problem being that by using terminate to close the keyboard, there is now a delay when opening the keyboard again as the process has to start up


I will have a look at the CreateProcess() Api as you suggested and see if I can make it work

 
starting tabtip.exe will always take a little time lag. I don't see a way to hide and show the keyboard, unless you click on the close button (upper right X) on the keyboard, which doesn't terminate it, but let's it slide to a screen side.

You could try to send a windows message to minimize the keyboard window, if you get the hwnd handle.

Bye, Olaf.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top