Is it neccessary to set collections, hashtables, sortedlists, .... to nothing if they are no longer used ? Maybe at the end of a subroutine or in the closing event of the application ?
Printable View
Is it neccessary to set collections, hashtables, sortedlists, .... to nothing if they are no longer used ? Maybe at the end of a subroutine or in the closing event of the application ?
You can if you want, and probably should if they take up an abnormal amount of resources. It isn't neccessary though because when an object goes out of scope, it is the garbage collectors job to deal with it. It is even good about finding circular references if you have them.