module win_installer.pywin32_helper

Short summary

module pymyinstall.win_installer.pywin32_helper

@grief Functions to help using pywin32.

source on GitHub

Functions

function

truncated documentation

fix_pywin32_installation

copy DLL at the right place

import_pywin32

For the module pywin32, this function tries to add the path to the DLL to PATH before throwing the exception: …

Documentation

@grief Functions to help using pywin32.

source on GitHub

pymyinstall.win_installer.pywin32_helper.fix_pywin32_installation(python_path=None, fLOG=<built-in function print>)[source]

copy DLL at the right place

Parameters
  • python_path – python path

  • fLOG – logging function

pywin32 does not work

To check module pywin32 is installed, you must run:

import win32com

If it displays the message ImportError: DLL load failed, it means it was not able to find DLLs pythoncom34.dll, pythoncom34.dll. Two solutions:

  • Add the folder C:\Python34_x64\Lib\site-packages\pywin32_system32

to environment variable PATH. That’s what function import_pywin32 is doing every time it is called. * Copy the two DLLs to C:\Windows\System32, that’s what function fix_pywin32_installation does if it is run with admin rights.

New in version 1.1.

source on GitHub

pymyinstall.win_installer.pywin32_helper.import_pywin32()[source]

For the module pywin32, this function tries to add the path to the DLL to PATH before throwing the exception: DLL load failed: The specified module could not be found.

It checks the instruction import win32com.

source on GitHub