Exit clicking X?

BlitzMax Forums/BlitzMax Programming/Exit clicking X?

Robby(Posted 2015) [#1]
Just a quick, likely simple question! If I am in windowed mode, how do I get the program to exit when the user click's the windows' x in the upper right? Can't seem to find info on this. Thanks, -Rob


grable(Posted 2015) [#2]
Check the result of AppTerminated and exit from your loop if its true.
There is also AppSuspended for knowing if the window has focus or not.


Robby(Posted 2015) [#3]
Thanks! I found I could pack it in an If..then block. Works like a charm!