Class_Terminate

Occurs when an instance of the associated class is terminated.
Occurs when the last reference to the object is released
This might happen when a variable goes out of scope
This might happen when the object is explicitly set to Nothing
Lets you perform clean up tasks

Class MyClass 

   Private Sub Class_Terminate()
'statements
   End Sub

End Class

This event is fired when a class object is destroyed

Set objMyClass = Nothing 


Creating

To add this event choose Class from the top left drop-down and then Terminate from the top right drop-down
SS



© 2019 Better Solutions Limited. All Rights Reserved. © 2019 Better Solutions Limited TopPrevNext