Get ClassID of different versions of program with same ProgID
ivanlocke at mail.com
Sat Jun 2 00:11:45 CEST 2007
I am new to Python and COM, but both seem very useful for automation
as AutoCAD, ArcGIS, and my gps software all have COM interfaces and
ArcGIS actually uses python scripts.
My trouble is that I am running two versions of AutoCAD (14 and 2004).
The problem is that both have the same ProgID.
When I use:
with no AutoCAD open, I get whichever version is set as default (I
tested switching my default).
With an AutoCAD session open, it will find the open session regardless
How can I get the ClassID of the different versions? I can connect to
them, is there some:
print acad.ClsID # Or something like that?
I have searched and searched and cannot find such.
I have also tried looking at the makepy, but trying the id numbers I
see there I just get errors:
'Class not registered'
Oh, one note, I don't have access to the registry (at least regedit),
so can't look up the ID's there. I tried pythoncom.GetClassFile, but
'Moniker cannot open file'
I am assuming because I don't have access to registry.
Thanks for the help,
More information about the Python-list