>If x is an external reference to an object adn you RELEASE THIS from within the object then the object will not release until you clear the external reference to it, therefore the need for x = .NULL.
I just assumed that x = Create("MyClass") means that x is a variable.
>As for RELEASE Object versus Object.Release() the former assume total control over the destruction of another object whose state may ro may not be know at the time. The latter, Object.Release(), requests that the object release itself (it knows its current state and can do whatever it needs to to clear that state and prepare for destruction). It is always a better design to allow an object to be responsible for its own destiny.
I agree. But I understood that the question is how to release an object assigned to variable when you don't know the name of that variable. Maybe I misunderstood it.
Vlad
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only