[python-win32] Subject: Re: win32com.client.gencache.EnsureModule works but win32com.client.Dispatch does not for a certain TypeLib
Tim Roberts
timr at probo.com
Thu Mar 28 17:47:47 CET 2013
Costis Hatzopoulos wrote:
>
> but I don't think that this is the problem, because from the same
> configuration i can script Excel 2007 32-bit and ZwCAD 2011 32-bit too!
Roger is quite correct in saying that you cannot load a 32-bit DLL into
a 64-bit process (or vice versa). That is an incontrovertible fact.
COM servers come in two styles: "in-process" and "out-of-process". An
in-process server loads as a DLL in your process. An out-of-process
server runs as a separate application; a stub DLL gets loaded into your
process that uses Remote Procedure Call to make requests into the
separate application.
Excel is an out-of-process COM server. That means it doesn't care about
your bittedness. I don't know about ZwCAD, but it might be the same.
If the COM server you are trying to access only supports "in-process"
serving (and many do), then you cannot use it from 64-bit Python.
--
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.
More information about the python-win32
mailing list