一次安装多个APK [英] installing multiple apks at once
问题描述
我想一次安装多个APK,因为我有一个可以执行所有操作的主应用程序,而其他所有应用程序都具有一项服务,并且必须将一项活动放置在设备上才能运行主APK.最好将它们包含在zip文件中,我知道会发生这种情况,因为su.zip会执行类似的操作
I wanted to install multiple APKs at a time because I am having one main app that does everything and all the other apps have a service and an activity that has to be put on the device for the main one to run, would it be best to include them in a zip I know something like this happens because su.zip does something similar
推荐答案
我必须执行类似的操作才能更新多个企业APK.我从REST API/数据库下载了APK.然后,一旦有了文件,我就可以通过调用以下程序开始在程序中安装应用程序:
I had to do something like this for updating my multiple Enterprise APKs. I downloaded the APK from a REST API/ database. Then once I had the file I started the install of the app in program by calling:
Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setDataAndType(Uri.fromFile(new File(fileName)), "application/vnd.android.package-archive");
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
context.startActivity(intent);
这将启动安装程序并安装APK.
This will start the installer and install the APK.
这篇关于一次安装多个APK的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!