End hook?

BlitzMax Forums/BlitzMax Programming/End hook?

JoshK(Posted 2006) [#1]
Any time my program ends, I just call CloseProgram(), which contains an End command. Is there any way to add a hook so that whenever End is called, my own custom function can be run automatically first?


Luke.H(Posted 2006) [#2]
Try:

OnEnd( fun() )


JoshK(Posted 2006) [#3]
Found it, thanks.