• android 调试崩溃Unable to instantiate application的解决方法


    E/AndroidRuntime: FATAL EXCEPTION: main
                      Process: com.***.plants, PID: 23100
                      java.lang.RuntimeException: Unable to instantiate application com.***.MyApplication: java.lang.ClassNotFoundException: Didn't find class "com.****.MyApplication" on path: DexPathList[[zip file "/data/app/com.****.plants-1/base.apk"],nativeLibraryDirectories=[/data/app/com.***.plants-1/lib/arm64, /system/fake-libs64, /data/app/com.***.plants-1/base.apk!/lib/arm64-v8a, /system/lib64, /vendor/lib64]]
                      at android.app.LoadedApk.makeApplication(LoadedApk.java:853)
                      at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5681)
                      ***
                      Caused by: java.lang.ClassNotFoundException: Didn't find class "com.***.MyApplication" on path: DexPathList[[zip file "/data/app/com.****.plants-1/base.apk"],nativeLibraryDirectories=[/data/app/com.***.plants-1/lib/arm64, /system/fake-libs64, /data/app/com.***.plants-1/base.apk!/lib/arm64-v8a, /system/lib64, /vendor/lib64]]
                      ***
     

    解决方法:

    打开设置:file->settings,搜索Instant Run,取消勾选Enable?Instant Run to***如图:

    关于Instant Run:是Android Studio2.0之后更新的一个强大的功能!在第一次运行之后,修改后的代码UI等不需要再build!可以快速再在真机上看到效果!节约生命

  • 相关阅读:
    谈谈关系类并查集
    并查集的应用
    关于欧拉线筛
    bzo4802 欧拉函数 miller_rabin pollard_rho
    数论
    前端切图:自制简易音乐播放器
    前端切图:自制简易音乐播放器
    SEO那些事:一句代码一键分享网站
    SEO那些事:一句代码一键分享网站
    前端调用百度API
  • 原文地址:https://www.cnblogs.com/bluestorm/p/11323038.html
Copyright © 2020-2023  润新知