win32com: _NewEnum being cached

Tom Hines tom_hines at my-deja.com
Fri Apr 28 22:46:04 CEST 2000


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().

I have a COM class that implements a dynamic collection, so I
need "for" blocks to result in calls to get__NewEnum() every time.
Does anybody know how to force this?

Thanks.

--
Tom Hines
Rockville, MD



Sent via Deja.com http://www.deja.com/
Before you buy.



More information about the Python-list mailing list