I create one application and never use finish() for each activity. If my user clicks on the logout button it goes to the previous page.
How can I close my previous
you can add a List in Application that save every activity you created. and when you exit, you just need to finish all activity in the list.