ImportError: DLL load failed: A device attached ...

Bill Bell bill-bell at bill-bell.hamilton.on.ca
Tue May 8 21:48:21 CEST 2001


>    From: "Thomas Heller" <thomas.heller at ion-tof.com>
> Subject: Re: ImportError: DLL load failed: A device attached ...
> 
> > I am having difficulty running one or two of the Win32 examples. The
> > last three lines of the diagnostic message in one case are:
> >
> > File "C:\Python21\win32\Demos\win32clipboardDemo.py", line 5, in ?
> > from win32clipboard import * ImportError: DLL load failed: A device
> > attached to the system is not functioning.
> >
> > Rather than trouble the subscribers to this list I have looked for
> > hints on the FAQ and elsewhere. Although I have yet to find an
> > answer I have noticed that quite a few people have experienced what
> > I am.
> >
> > Would it be possible for someone to sketch one or two of the best
> > ways of approaching a Python problem like this one? Is there some
> > way of making the 'import' indicate what DLLs might be missing or
> > other cause of the failure?
> >
> > Thanks for any suggestions!
> >
> I assume you are running win98. Hint: NT or win 2000 usually
> names the DLL's failing to load.
> 
> On win98 I would suggest the following procedure:
> Determine the dll failing to load (in this case it seems to
> be win32clipboard.pyd).
> 
> The dependencywalker tool from http://www.dependencywalker.com/,
> when run on win32clipboard.pyd should be able to show the problem.
> 
> Hope this helps (and works)
> 
> Thomas

Thanks, Thomas. Yes, that helps. MInd you, I dunno what to do 
now that you've found the precise cause for me. 

Apparently WIN32CLIPBOARD.PYD calls 
GetClipboardSequenceNumber in user32.dll. I'm using Python on a 
Win95 machine (you were almost right about that).

Similarly WIN32NET.PYD references quite a few unavailable 
procedures in netapi32.dll.

I wonder if this means, in essence, that one cannot use these 
Python DLLs with ancient versions of Windows?

Thanks again.

Bill




More information about the Python-list mailing list