Getting ActivePython to work with WSH

I installed ActivePython 2.7.2 and I try to run a .pys script through the console using wscript / cscript, [ie ActivePython (PythonScript with the .pys extension) in Microsoft WSH (Windows Scripting Host)], and when I try using wscript I get two mistakes.

  • "The program cannot start because MSVCR90.dll is missing on your computer, try reinstalling the program to fix this problem"
  • "Cannot find script Python engine for script

I did some search queries, and also downloaded and installed the following Microsoft Visual C ++ (x86) distribution package: http://www.microsoft.com/download/en/confirmation.aspx?id=29 to no avail.

I tried 'pythonw c: \ Python27 \ Lib \ site-packages \ win32comext \ axscript \ client \ pyscript.py' to register python.

Any help would be greatly appreciated.

I am running on Win7 x86.

+7
source share
1 answer

To fix this:

  • Install Python for Windows Extensions (PyWin32)
  • Register python, C:\YourPythonVersion\Lib\site-packages\win32comext\axscript\client\pyscript.py
+5
source

All Articles