variant com issues/problems in python

Matt Smith s0199583 at
Tue Aug 12 10:39:16 CEST 2003

Hi, all.

Just a quick question, when setting a COM process to read a value from
a pre-defined register index, I think, I have to change the variable
that the value will be returned to (as I have to do for the same
function in perl), into a VARIANT, However when i run the variant

      'serialIndex = win32com.client.pythoncom.VT_VARIANT' 

no matter what extension I use (i.e. VT_I4 or VT_BOOL etc etc) it
still returns a type mismatch error. I may be doing something wrong or
getting confused with variant processes in python. I do know the code
I use in perl to do this works but I dont know how to translate this,
fully, into python.

perl code for variant =

Cheers in advance,

More information about the Python-list mailing list