FAQ
I'm running Python 2.6 under XP.

I've installed Windows 32 extensions for Python 2.6 version 1.4
(pywin32-214.win32-py2.6.exe).

But If I try to import win32api, I get:

File "C:\python_projects\euler\driveletters.py", line 1, in <module>
import win32api
ImportError: DLL load failed: The specified module could not be found.

\Python26\Lib\site-packages has:

03/23/2009 08:35 AM <DIR> win32
07/20/2009 09:08 AM <DIR> win32com
02/18/2009 01:21 PM <DIR> win32comext

Can anyone offer a suggestion?

Thanks,

Gerry

Search Discussions

  • Tim Golden at Jul 20, 2009 at 1:57 pm

    Gerry wrote:
    I'm running Python 2.6 under XP.

    I've installed Windows 32 extensions for Python 2.6 version 1.4
    (pywin32-214.win32-py2.6.exe).

    But If I try to import win32api, I get:

    File "C:\python_projects\euler\driveletters.py", line 1, in <module>
    import win32api
    ImportError: DLL load failed: The specified module could not be found.
    Used to be you'd get this error if you installed as a
    non-admin user. Don't know if that's still an issue.
    Possibility?

    TJG
  • MCIPERF at Jul 20, 2009 at 5:28 pm

    On Jul 20, 9:57?am, Tim Golden wrote:
    Gerry wrote:
    I'm running Python 2.6 under XP.
    I've installed Windows 32 extensions for Python 2.6 version 1.4
    (pywin32-214.win32-py2.6.exe).
    But If I try to import win32api, I get:
    ? File "C:\python_projects\euler\driveletters.py", line 1, in <module>
    ? ? import win32api
    ImportError: DLL load failed: The specified module could not be found.
    Used to be you'd get this error if you installed as a
    non-admin user. Don't know if that's still an issue.
    Possibility?

    TJG
    Not a possibility (afaict) -- I am an administrator, according to the
    control panel.
  • Tim Golden at Jul 21, 2009 at 5:07 pm

    MCIPERF wrote:
    On Jul 20, 9:57 am, Tim Golden wrote:
    Gerry wrote:
    I'm running Python 2.6 under XP.
    I've installed Windows 32 extensions for Python 2.6 version 1.4
    (pywin32-214.win32-py2.6.exe).
    But If I try to import win32api, I get:
    File "C:\python_projects\euler\driveletters.py", line 1, in <module>
    import win32api
    ImportError: DLL load failed: The specified module could not be found.
    Used to be you'd get this error if you installed as a
    non-admin user. Don't know if that's still an issue.
    Possibility?

    TJG
    Not a possibility (afaict) -- I am an administrator, according to the
    control panel.
    Not too many ideas, then, I'm afraid. Apart from the obvious --
    uninstall and try again -- how about running Python with the
    -vv option:

    python -vv

    to get more information about what it's trying to get,
    and/or running sysinternal's Process Explorer at the
    same time to spot the DLL Dependencies.

    I have seen a (not too similar) problem when running TortoiseHg
    and the pywin32 extensions, since the shell import's TortoiseHg's
    version of various pywin32 DLLs before I try to import them
    myself for some other purpose, and the two versions clashed
    dramatically (crashed Explorer hard, I seem to remember).

    Just in case that rings any bells..

    TJG
  • Tim Roberts at Jul 22, 2009 at 7:09 am

    Gerry wrote:
    I'm running Python 2.6 under XP.

    I've installed Windows 32 extensions for Python 2.6 version 1.4
    (pywin32-214.win32-py2.6.exe).

    But If I try to import win32api, I get:

    File "C:\python_projects\euler\driveletters.py", line 1, in <module>
    import win32api
    ImportError: DLL load failed: The specified module could not be found.

    \Python26\Lib\site-packages has:

    03/23/2009 08:35 AM <DIR> win32
    07/20/2009 09:08 AM <DIR> win32com
    02/18/2009 01:21 PM <DIR> win32comext

    Can anyone offer a suggestion?
    It is very unusual that those three directories should have different
    creation dates. Normally, all three would have the same date and time,
    from whenever you ran the installer.

    I would suggest that you go into Add and Remove Programs, uninstall
    pywin32, and run the installer again.
    --
    Tim Roberts, timr at probo.com
    Providenza & Boekelheide, Inc.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppython-list @
categoriespython
postedJul 20, '09 at 1:47p
activeJul 22, '09 at 7:09a
posts5
users3
websitepython.org

People

Translate

site design / logo © 2022 Grokbase