Importerror no module named WIN32API

Discussion in 'Python' started by Matt Smith, Aug 11, 2003.

  1. Matt Smith

    Matt Smith Guest

    hi all, again....

    having another problem with python COMs, I run a python script on a
    win2000 machine, that uses win32com.client and it runs perfectly,
    whereas when I come to run it on a win98 machine (the machine that the
    code, when completed, will be running from in the future) it returns
    the error:

    Traceback (most recent call last):
    File "firsttry.py", line 1, in ?
    import helloworld
    File "G:\msmith\python\helloworld.py", line 2, in ?
    import win32com
    File "C:\PYTHON23\lib\site-packages\win32com\__init__.py", line 5,
    in ?
    import win32api, sys
    ImportError: No module named win32api

    Any clues as to how to rectify this problem would be greatly
    appreciated

    cheers,
    matt.
     
    Matt Smith, Aug 11, 2003
    #1
    1. Advertising

  2. Matt Smith

    Matt Smith Guest

    Joe Francia <> wrote in message news:<ggSZa.2128117$>...
    > Matt Smith wrote:
    >
    > > hi all, again....
    > >
    > > having another problem with python COMs, I run a python script on a
    > > win2000 machine, that uses win32com.client and it runs perfectly,
    > > whereas when I come to run it on a win98 machine (the machine that the
    > > code, when completed, will be running from in the future) it returns
    > > the error:
    > >
    > > Traceback (most recent call last):
    > > File "firsttry.py", line 1, in ?
    > > import helloworld
    > > File "G:\msmith\python\helloworld.py", line 2, in ?
    > > import win32com
    > > File "C:\PYTHON23\lib\site-packages\win32com\__init__.py", line 5,
    > > in ?
    > > import win32api, sys
    > > ImportError: No module named win32api
    > >
    > > Any clues as to how to rectify this problem would be greatly
    > > appreciated
    > >
    > > cheers,
    > > matt.

    >
    > Maybe you need to install the win32all extensions on the Win98 machine?
    > http://starship.python.net/crew/mhammond/
    >
    > jf


    jf was that supposed to be funny ?

    no i would like a serious answer to this problem, as it is seriously hampering
    my current project.

    cheers,
    matt
     
    Matt Smith, Aug 12, 2003
    #2
    1. Advertising

  3. Matt Smith wrote:

    > > > ImportError: No module named win32api
    > > >
    > > > Any clues as to how to rectify this problem would be greatly
    > > > appreciated

    > >
    > > Maybe you need to install the win32all extensions on the Win98 machine?
    > > http://starship.python.net/crew/mhammond/

    >
    > jf was that supposed to be funny ?
    >
    > no i would like a serious answer to this problem, as it is seriously hampering
    > my current project.


    have you checked the "Installation Problems" page (available via the funny
    link)?

    http://starship.python.net/crew/mhammond/win32/InstallationProblems.html

    have you checked that win32api is installed, and that python is picking up
    the right win32api version? have you checked the python path? have you
    traced the imports (use "python -v" or "python -vv" to run the program)?
    if win32api exists, what happens if you import it from the python prompt?
    are all DLLs that win32api depends upon available on your machine (google
    for DLL dependency checkers, or use "dumpbin /imports" to check what it
    relies on). etc.

    </F>
     
    Fredrik Lundh, Aug 12, 2003
    #3
  4. Matt Smith

    Matt Smith Guest

    Thanks for the ehlp, it was the pythonpath or rather the lack of one
    that was causing me difficulties,

    thanks again,
    matt
     
    Matt Smith, Aug 12, 2003
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Harry George
    Replies:
    0
    Views:
    5,711
    Harry George
    Jul 15, 2003
  2. Mikael Olofsson
    Replies:
    0
    Views:
    442
    Mikael Olofsson
    Jul 16, 2003
  3. Carsten Gehling

    pso - ImportError: No module named url

    Carsten Gehling, Jul 16, 2003, in forum: Python
    Replies:
    0
    Views:
    387
    Carsten Gehling
    Jul 16, 2003
  4. eric_bellard
    Replies:
    1
    Views:
    5,112
    CarlosRivera
    Oct 7, 2004
  5. Mike
    Replies:
    0
    Views:
    1,445
Loading...

Share This Page