How to close your app programmatically

will do the trick. Shutdown happens immediately. If you do this in a live app it’s probably a good idea to let the user know and wait for a button click, or perhaps integrate a timer before the shutdown occurs.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.