Procedure forcerelease() Local Array lainstances[1] Ainstance(lainstances,This.Class) Local lnCount, loReference For lnCount = 1 To Alen(lainstances,1) Try loReference = Evaluate(lainstances(lnCount)) Catch Debugout "reference "+lainstances(lnCount)+" not accessible" loReference = .Null. Endtry If Vartype(loReference)="O" If Pemstatus(loReference,"cID",5) And loReference.cID=This.cID Try If !Pemstatus(loReference,"forcerelease",5) * should never be the case as we try to force release of this class * and this class has a forcerelease method. Debugout "reference "+lainstances(lnCount)+" to "+This.Class+; " without forcerelease() method!" Else loReference = .Null. Debugout "try to kill reference "+lainstances(lnCount) Execscript(lainstances(lnCount)+" = .null.") * side note: There is no need to call forcerelease of that instance, * as we already loop over every instance... Endif Catch Debugout "failed to kill reference "+lainstances(lnCount) Endtry Endif Endif loReference = .Null. Endfor Debugout "try to kill THIS" THIS = .null. Endproc