win32com: _NewEnum being cached
Mark Hammond
mhammond at skippinet.com.au
Fri Apr 28 19:31:44 EDT 2000
"Tom Hines" <tom_hines at my-deja.com> wrote in message
news:8ecta7$nn5$1 at nnrp1.deja.com...
> Hello. As you know, to implement "for x in my_list" functionality in
> COM, you must code a get__NewEnum() function, which I have done and it
> works fine under Visual Basic. But when called from Python, the call
> seems to get cached, as subsequent Python "for" blocks don't result in
> calls to get__NewEnum().
You should be able to say:
enum = ob._NewEnum()
for i in enum:
...
Mark.
More information about the Python-list
mailing list