win32com, access of 2-dimensional Property

xx xx at xx.com
Wed May 15 03:04:01 EDT 2002


Thank you, Mark.

I solved the problem, I was so excited yesterday about my
30 minutes trail running the ActiveX interface from python
program (2 days work) and replace the 3-year work ( M$ Visual C++)
of my colleagues, that I forgot my basics :-)))

The solution is:
data = cam.Image[100][100]

Markus


Mark Hammond schrieb:

> Markus von Ehr wrote:
> > Hi,
> >
> > I use an ActiveX Interface for an Apogee camera.
> > The code works, the only problem I have is to
> > retrieve the Image data which is a twodimensional
> > ReadOnly Property of Data Type Variant.
> > Does Anybody know how to access these types?
> > This doesnt work: cam.Image(100, 100), cam.Image("100", "100")
> > neither cam.Image[100, 100]
>
> You should run makepy over the type library for the object, and have a
> look.  You may find that you need to do something like:
>
> data = cam.Image.Value
> # data is now a tuple of tuple representing the data
>
> or maybe something like:
> data = cam.Image.Item(100,100)
>
> etc.
>
> Mark.




More information about the Python-list mailing list