Sorry, but no it is not possible. The problem is that once the iOS device is "sleeping", there is nothing the program can do. It cannot "wakeup" from sleep.
Doing a backup during exit is also not possible. Once the shut down process is started, it will kill the app before that could be done. Also if you do not have internet access or was sporadic, it would not be possible without some sort of user feedback.