IF I understand correctly the timer is a property of the control ?
If so kill the timer when the controls close method or event is called so the timer stops when the control & its property are destroyed
Or is the timer a property of the Window the control is on ?
If so use the Windows close method/event
If this is a window subclass you can override the Close method and implement the close /cancel close events and pass them along with raise event as well
The underlying issue is that a timer with a weak address target for he action event handler doesnt check if the target is nil before trying to call it
Xojo should just fix that so it does then this problem goes away in general