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 

Warning Message: "The keyboard and/or mouse hook could(

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



Joined: 13 Sep 2006
Posts: 4

PostPosted: Mon Sep 25, 2006 3:24 pm    Post subject: Warning Message: "The keyboard and/or mouse hook could( Reply with quote

First of all thanks to Roland, Laszlo and PhiLho for helping me out with my last problem.

My new problem: I've written a script that gathers information from certain windows and saves them in an HTML file - this is done by checking for mouse clicks on specified buttons. Everything worked fine until I ran it on other computers in the office. Every second computer gave the following warning message when starting AutoHotkey (prior to any other commands in the script):

"Warning: The keyboard and/or mouse hook could not be activated; some party of the script will not function."

This warning message, I believe, was given by AutoHotkey itself (but I'm not completely sure). Whenever this message appears, the script still reacts to the implemented keyboard hotkeys, but not to the vital mouse click checks. When running the program from a network drive, instead of a local drive, most of the computers did not show this warning any more (the script then working flawlessly), but not all. Adding "#InstallMouseHook" to the top of the script did not solve the problem.

Any ideas what the problem could be and/or how to solve it permanently?
Back to top
View user's profile Send private message
PhiLho



Joined: 27 Dec 2005
Posts: 6836
Location: France (near Paris)

PostPosted: Mon Sep 25, 2006 3:52 pm    Post subject: Reply with quote

What are the OSes you are using? Hooks doesn't work in Win9x, because it needs an external DLL.
Perhaps also it needs Administrator rights, although I doubt it.
_________________
vPhiLho := RegExReplace("Philippe Lhoste", "^(\w{3})\w*\s+\b(\w{3})\w*$", "$1$2")
Back to top
View user's profile Send private message Visit poster's website
Squis



Joined: 13 Sep 2006
Posts: 4

PostPosted: Mon Sep 25, 2006 3:56 pm    Post subject: Reply with quote

The same OS on all computers: Windows XP
Back to top
View user's profile Send private message
Chris
Site Admin


Joined: 02 Mar 2004
Posts: 10716

PostPosted: Tue Sep 26, 2006 10:21 pm    Post subject: Reply with quote

This is a rare error and I'm not sure what could cause it other than some OS restriction or driver/program that's preventing AutoHotkey.exe from using the OS-provided low-level mouse/keyboard hook.

An error like this could mean that you have some software installed that has deliberately modified your system to disable the mouse/keyboard hooking. Perhaps its reason for doing this is to prevent other software from detecting keystrokes and mouse clicks.
Back to top
View user's profile Send private message Send e-mail
Mountie



Joined: 30 Oct 2007
Posts: 20

PostPosted: Sat Nov 14, 2009 5:47 am    Post subject: Reply with quote

I recently started having the same problem as Squis; that is,
"Warning: The keyboard and/or mouse hook could not be activated; some party of the script will not function."

I can't figure out what could be causing this. I've tried the #InstallKeybdHook and #InstallMouseHook directives and still get the same message. I'm using Windows XP. Is there a way to find out what process is blocking the keyboard/mouse hooks and/or how to re-enable them?

Thank you.
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