Is there a way to close the iPhone app from within the app? A client asked me if there was a way to close the app by pushing a button in the app, without manually doing it by double tapping the home button and then press-hold the app icon and then hit the – sign.
Apparently, the client wants to build an app which uses bluetooth and ANT+ devices which are battery hogs and wants the ability to quickly close the app.
Any thoughts?
Aside from quitting from a button within the application being against the Apple Human Interface Guidelines, it isn’t even recommended behaviour.
But if you still want to close your app. Use ‘exit();’.