Called by the garbage collector when the current object is ready to be finalized.
[Visual Basic] Overrides Protected Sub Finalize() [C#] protected override void Finalize(); [C++] protected: override void Finalize(); [JScript] protected override function Finalize();
Exception Type | Condition |
---|---|
IOException | An I/O error occurs. |
Finalize closes the FileStream.