Erf Erf - 9 months ago 31
Android Question

Can it be possible to disable complete action using?

below code download file from url :

Intent intent=new Intent(Intent.ACTION_VIEW, Uri.parse("http://www.google.com/Erfan/update.apk"));
startActivity(intent);


but before download complete action using come and I don't want this. I want the download to start without asking complete action using like when we use http connection in AsyncTask way. Is this possible ?

Answer Source

That isn't how you download something. That's how you launch an activity that claims to read websites, and tell it to open that website. If you want to download something, either use an HTTP connection of your own or use DownloadManager.