错误信息如下:
Installation failed with message INSTALL_FAILED_USER_RESTRICTED.
It is possible that this issue is resolved by uninstalling an existing version of the apk if it is present, and then re-installing.
WARNING: Uninstalling will remove the application data!
Do you want to uninstall the existing application?
INSTALL_FAILED_USER_RESTRICTED:
手机系统中有应用阻止了安装,比如像魅族手机中的手机管家有监控usb安装apk的权限。关闭此权限,即可。
解决方案:
1.在手机开发者选项打开“usb安装”
{
魅族手机:打开手机管家--点击权限管理--点击USB安装管理--关闭USB安装管理
小米手机:在手机的开发者模式中关闭MIUI优化
}
2.设置Android Studio 中Instant Run中的选项为不选中(路径:File -- Settings--Build,Execution,Deployment--Instant Run)
3.更改签名文件
下面是从网上找到的几种常见的错误及解决方法:
1、INSTALL_FAILED_