安装 Android 更新 - “应用程序未安装”错误

发布于 2024-12-18 23:24:35 字数 284 浏览 5 评论 0原文

我最近对现有应用程序进行了更改,我们希望将更改作为可下载更新推送给我们的用户。

应用程序识别出有更新,并下载该文件。下载后,我们可以点击apk文件,它说它将替换现有的应用程序。我们单击“确定”,然后单击“安装”并收到一条消息,仅显示“应用程序未安装”。

我们希望这是到新更新的无缝过渡,因为我们有大约 1000 位用户需要此更新才能使我们公司顺利运行。

两个应用程序(旧版本和新版本)均使用相同的证书签署 APK。让每个用户手动卸载然后安装新版本并不是一种选择,因为我们给予他们对其手机功能的有限访问权限。

I have recently made a change to an existing app and we would like to push out the changes to our users as a downloadable update.

The application recognizes that there is an update, and downloads the file. After the download, we can click on the apk file and it says that it will replace an existing application. We click OK, then click Install and get a message simply saying "Application Not Installed."

We would like this to be a rather seamless transition to the new update as we have ~1000 users that will need this update for our company to run smoothly.

Both applications (old version and new version) are signed APK's with the same certificate. Having each user uninstall manually then install the new version is not an option as we have given them limited access to their phone features.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

我恋#小黄人 2024-12-25 23:24:35

如果不查看日志和/或清单文件,很难确定,但需要快速查找一些内容:

在 AndroidManifest.xml 文件中,检查以确保:

  1. 每个版本中的包名称完全相同
  2. 版本代码 是一个整数大于之前的版本
  3. 每个版本的 versionName 都不同

Hard to be definitive without seeing logs and/or manifest files, but some quick things to look for:

In the AndroidManifest.xml file, check to make sure:

  1. The package name is exactly the same in each version
  2. the versionCode is an integer that is greater than that of the previous version
  3. The versionName is different for each version

    <manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="XXXXX"
    android:versionCode="2"
    android:versionName="2.1.0 Fred">

孤君无依 2024-12-25 23:24:35

确保两个应用程序具有相同的构建变体(即productRelease-productRelease等)。就我而言,这就是问题的原因。

Make sure that both applications have the same build variant (ie productRelease - productRelease etc.). In my case it was the reason of the problem.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文