I have a .DLL that I am extracting the file version from using wmi.py. The specific code is:
c = wmi.WMI() for f in c.CIM_DataFile(Name="c:\\glossersdmsservices\\bin\\glosscmanager.dll"): sdmsver = f.Version this works fine when running the application as a python file, when I build the application into an executable, using py2exe, I get the following error: Traceback (most recent call last): File "autoStart.pyc", line 241, in test File "wmi.pyc", line 138, in ? File "win32com\client\gencache.pyc", line 540, in EnsureDispatch File "win32com\client\CLSIDToClass.pyc", line 50, in GetClass KeyError: '{D2F68443-85DC-427E-91D8-366554CC754C}' the .dll resides outside the directory of the executable. The one thing I notice is that the KeyError value is a different id than the COM object I am accessing. I'm not sure where the value in the KeyError listed is coming from. Do I have to do some preprocessing in the build script? I am at a bit of a loss here, so any input would be appreciated. Thanks in advance. -- http://mail.python.org/mailman/listinfo/python-list