AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

VirtualBox steals keys...

 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
tinaa



Joined: 25 Nov 2004
Posts: 57

PostPosted: Sat Nov 28, 2009 11:07 pm    Post subject: VirtualBox steals keys... Reply with quote

Hi,

I've got Autohotkey running in Windows 7 64bit. I've got a Virtualbox virtual machine running in the background. Even though I've disabled the automatic keyboard grabbing feature for the virtual machine, for a number of hotkeys I use somehow some of the key strokes get stolen by the virtual machine instead of behaving as they should. For some reason most of the hotkeys where I've defined Windowskey+something just bring the virtual machine to the foreground and don't execute the script. And sometimes the windowskey or other modifier keys get stuck in the down state.

The only way to fix things is to reload the running scripts. If ctrl,alt or shift are stuck I need to press them physically on the keyboard to unstick them.

Is there any workaround to prevent Virtualbox from messing with Autohotkey?

Thanks.
Back to top
View user's profile Send private message
mklement



Joined: 02 Jun 2010
Posts: 3

PostPosted: Wed Jun 02, 2010 6:50 pm    Post subject: Reply with quote

I PARTLY have the same problem: modifier keys get stuck when I use them as part of a hotkey definition to activate a VM's window when control is returned to the host.

Here's what worked for me:
To avoid this problem, precede the VM-window-activation command in your AHK script with the following lines (the example is based on the two modifier keys *I* use for activation; adapt accordingly):
; Wait for both Control and Alt to be released before activating the VM's window.
KeyWait Control
KeyWait Alt
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group