1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- .. _func_system_onend:
- =====
- OnEnd
- =====
- OnEnd -
- Description
- ===========
- .. code-block:: blitzmax
- OnEnd( fun() )
- Add a function to be called when the program ends
- #OnEnd allows you to specify a function to be called when the program ends. OnEnd functions are called
- in the reverse order to that in which they were added.
- Parameters
- ==========
- Return Values
- =============
- Nothing.
- Examples
- ========
- .. code-block:: blitzmax
- ' onend.bmx
-
- Function cleanup()
- Print "cleaning up"
- End Function
-
- OnEnd cleanup
- Print "program running"
- End 'the cleanup function will be called at this time
- See Also
- ========
|