> If I have an object MYCONTROL that has a reference to object A that
> subscribes to an event of object B and has a reference to object B in
> its Items collection that is a member of object A. Object B also has
> a reference varialbe Parent that points to object A. If I null the
> reference to object A in MYCONTROL, will object A and B get garbage
> collected or will they live forever in their circular reference?
A circular reference in unreferenced data doesn't trouble the garbage
collector at all. That is, if no live data refers to A or B, they will
be collected, no matter how many different ways they refer to each
other.

Signature
www.midnightbeach.com
Allen Anderson - 14 Jan 2005 22:31 GMT
great, that's exactly the part I was wanting to make sure of. Thanks
for the info.
>> If I have an object MYCONTROL that has a reference to object A that
>> subscribes to an event of object B and has a reference to object B in
[quoted text clipped - 7 lines]
>be collected, no matter how many different ways they refer to each
>other.