- First I have a server.I check server is there any
new apkfile I download this and try to install. - If server have
new version of apk filethen I want to update my .apk file. - I want to Install/update without user interaction.Is it possible?
- If user interaction is needed then How can I install/update .apk file.
I don’t have idea much more about that.
Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setDataAndType(Uri.fromFile(new File(Environment.getExternalStorageDirectory() + "/download/" + "jarviz.apk")), "application/vnd.android.package-archive");
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
But this is not working.WHen I debugging I can not see any mistake but it does not install.How can I do that.Sorry for bad English.
I solved the issue this way.