Project

General

Profile

Actions

Comtypes installation

THIS INSTRUCTION IS FOR comtypes 0.6.2. If you install newer version, this may not work.

Double click on the installer

Modify comtypes

IMPORTANT: After installing comtypes, you must make one modification to it. The module "safearray.py" that comes with comtypes must be replaced with a modified version that we provide. You can find the custom version of safearray.py in the pyscope package. Please copy this module from pyscope into the installed comtypes folder: C:\Python2*\Lib\site-packages\comtypes\. It should replace the safearray.py that is included in comtypes.

Remove safearray.pyc in C:\Python2*\Lib\site-packages\comtypes\ if it does not appear to recompile (timestamp of the file change) when you import comtype in python command line

import comtypes

Run checkcom.py

  • From a command line window:
    cd C:\python27\Lib\site-packages\pyscope
    C:\python27\python.exe checkcom.py

The module it finds depends on the module.

Updated by Anchi Cheng over 2 years ago · 3 revisions