[python-win32] Using the COM interface of Infinion Memtool

Markus Hubig mhubig at imko.de
Fri Apr 9 17:54:51 CEST 2010


Hi together,

i'm trying to use Infinion's Memtool via it's COM interface in my python
program. I've created an early binding file <http://pastie.org/911543> with
the makepy utility and
now I try to figure out how I can use it ...

I got five classes which I can use to get access to all the features of
Memtool.

-----------------8<---schnipp------------------------
from win32com.client import CoClassBaseClass
class SMTFlashMod(CoClassBaseClass): # A CoClass

# This CoClass is known by the name 'SMT.Memtool.1'
class SMTMemtool(CoClassBaseClass): # A CoClass

# This CoClass is known by the name 'SMT.SerPort.1'
class SMTSerPort(CoClassBaseClass): # A CoClass

# This CoClass is known by the name 'SMT.TargInfo.1'
class SMTTargInfo(CoClassBaseClass): # A CoClass

# This CoClass is known by the name 'SMT.TargIntf.1'
class SMTTargIntf(CoClassBaseClass): # A CoClass
-----------------8<---schnapp------------------------

and exept the first class "SMTFlashMod" all classes have a comment
telling me there "COM" name, so I can make an instance like that:

>>> fm = win32com.client.Dispatch("SMT.Memtool.1")
>>> sp = win32com.client.Dispatch("SMT.SerPort.1")
>>> ti = win32com.client.Dispatch("SMT.TargInfo.1")
>>> tf = win32com.client.Dispatch("SMT.TargIntf.1")

But How can make a instance on the SMTFlashMod Class? Here
http://pastie.org/911543 you can find the whole early binding file ...

Thanks for your help, Markus
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-win32/attachments/20100409/20cd4e24/attachment.html>


More information about the python-win32 mailing list