running android application in background [closed]
in my application when I click on exit button the application has to run in background or my hme screen must be visible how do i do this i am new to android i have no idea about it
What you are looking for is an android service. Please read this introduction, and paticulary the part about the different kinds of application component.
In order to have your application run in the background, you need to create a service. You can read a short tutorial here. Be advised that there are battery concerns for having an application run all the time, so only do it if you absolutely need to.
You can use Service to handle the core logic of your app, and put a notification icon on the status bar. When the user check out the notification, you can display your UI and get logic data from your Service.
精彩评论