Re: [python-win32] issues with win32com constants and static/dynamicdispatch

2007-07-04 Thread Jason Ferrara
c = win32com.client.Dispatch(c.QueryInterface(pythoncom.IID_IDispatch)) works. Thanks! FYI, c=win32com.client.Dispatch(c) does not. >>> c=win32com.client.Dispatch(c) Traceback (most recent call last): File "", line 1, in File "C:\Python25\Lib\site-packages\win32com\client\__init__.py", l

Re: [python-win32] issues with win32com constants and static/dynamicdispatch

2007-07-04 Thread Mark Hammond
That is strange - the problem is that the resulting COM object is returning an IUnknown rather than an IDispatch. A work around should be to say: c = cams[0] c = win32com.client.Dispatch(c) or possibly: c = win32com.client.Dispatch(c.QueryInterface(pythoncom.IID_IDispatch)) I think we could al