Dave Watts wrote: > If you want to reuse it, just redeclare it. If you want it to be > garbage-collected (you don't want to reuse it), things become a bit > more complicated I think.
There's not a way of forcing garbage collection that I know of. You can make an array eligible for garbage collection by removing all references to it (e.g., myArray = null should do it). There are two ways of re-declaring it so you can use it over. myArray = []; will do it, as Dave mentioned. myArray = new Array(); will also do it. I believe that frees up the space used by your array, and it can be garbage collected. The Flash VM has its own ideas about when garbage collection happens, though--you can make something available for garbage collection, but, as I said, you can't force it. Cordially, Kerry Thompson _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders