|
#1
|
|||
|
|||
|
Simple question:
Using the .SendKeys method, how do you call the 'windows key' on a keyboard? ******* * g707 * ******* |
|
#2
|
|||
|
|||
|
Still no luck on finding answer on this one... Anyone out there know this one?
******* * g707 * ******* |
|
#3
|
|||
|
|||
|
"Sendkeys" sends keystrokes to the active window. The "Windows" key does not go to a window, it goes to the operating system.
|
|
#4
|
|||
|
|||
|
Remember CTRL + ESC? set WshShell = CreateObject("WScript.Shell") WshShell.SendKeys "^{ESC}" Set WshShell = Nothing Jama |
|
#5
|
|||
|
|||
|
Thanks Jama, but not exactly what I was looking for. I wasn't looking to bring up the Start Menu, instead I wanted to use the hotkeys that can be used with WinKey.
** Brf, thanks for the explaination. After searching the web I couldn't find anyone who was able to emulate the WinKey and everyone acknowledged it, but I couldn't find the reason why. ******* * g707 * ******* |
|
#6
|
|||
|
|||
|
The "reason why" is because the BIOS and/or operating system read the keyboard as down/up keyboard scan events, not ASCII characters. The keyboard event handler processes the scan events and determines what to do: to place an ASCII value on the input queue, to perform a special subroutine or to do nothing. If the scan sequence is associated with a special subroutine then the subroutine is called and the application that had the focus is never even aware that a keyboard entry had been made as nothing is placed on the input queue. A classic example is Ctl-Alt-Del. The Windows key is a modern equivalent.
The SendKeys method places ASCII values on the input queue, simulating a case where a set of keyboard scan events had already been interpreted as a regular ASCII character entry. There is no way to simulate keyboard scan events from within WSH (unless you create a custom DLL to make that feature available to your application). |
|
#7
|
|||
|
|||
|
What exactly are you trying to achieve? There might be a way around the WinKey limitation! Jama |
![]() |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
| Display Modes | |
|
|
All times are GMT. The time now is 04:18 AM.







Linear Mode
