Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

import pyHook failed

I Have installed pyHook for my windows 64 bit.The setup has installed it in C:\Python27\Lib\site-packages dir i cant import pyhook (i can see win32 named folder there think so it is its folder) in my code what should i do Here is interpreters output

>>> import pyHook

Traceback (most recent call last):
  File "<pyshell#0>", line 1, in <module>
    import pyHook
ImportError: No module named pyHook
>>> import pyhook

Traceback (most recent call last):
  File "<pyshell#1>", line 1, in <module>
    import pyhook
ImportError: No module named pyhook
>>>  
like image 857
Danny Rock Avatar asked Sep 07 '15 21:09

Danny Rock


1 Answers

First of all win32 is not the pyHook module it is an other module.

Here is how to install pyHook:

1.You can find the download link here http://www.lfd.uci.edu/~gohlke/pythonlibs/#pyhook

2.If you have python 32bit you want pyhook 32 bit (Download #1 for Python 2.7).

3.If you have python 64bit you want pyHook 64 bit (Download #2 for Python 2.7).

4.Extract the zip file.

5.In the command prompt navigate to the folder where you extracted the .zip.

6.Type the command 'pip install pyHook-1.5.1-cp27-none-win32.whl' for the 32 bit version or 'pip install pyHook-1.5.1-cp27-none-win_amd64.whl'

Good Luck!

like image 117
staad Avatar answered Oct 04 '22 00:10

staad