I have a file downloading android application.Here file is downloaded when user click on listview items.It works fine.
Now,I want to cancel current file download and start next file while user taps on other items and another download is already progressing and show user confirmation before canceling the download task.
How can i do this?
Thanks in Advance
First, you must check in your
AsyncTaskIn your activiy, whenever you try to cancel, just cancel
AsyncTaskmanually, and of course, start a new one to download another file!