COM/win32all QueryInterface

Mark Hammond mhammond at
Mon Jan 6 23:50:56 CET 2003

Ellers wrote:
> actualObject = unk.QueryInterface( mod.MyConcreteClass.CLSID,
> pythoncom.IID_IDispatch )
> print "Actual:", actualObject 
> # prints something like <PyIDispatch at 0xcd39e4 with obj at 0x1492bc>

Pass this to win32com.client.Dispatch(), and you get a friendly wrapper 
around the IDispatch object, which allows you to call IDispatch 
implemented methods.


More information about the Python-list mailing list