当前位置:   article > 正文

java.lang.NoSuchFieldError: No static field septal_line3 of type I in class com/example/xxxxx/xxxxxx

java.lang.NoSuchFieldError: No static field septal_line3 of type I in class com/example/xxxxx/xxxxxx
  1. 03-27 08:41:48.942 29308-29308/com.xx.xxxxxxxxxxxxx E/AndroidRuntime: FATAL EXCEPTION: main
  2. Process: com.xx.xxxxxxxxxxxxx, PID: 29308
  3. java.lang.NoSuchFieldError: No static field septal_line3 of type I in class com/example/xxxxx/xxxxxxxxxx/R$id; or its superclasses (declaration of 'com.example.xxxxx.xxxxxxxxxx.R$id' appears in /data/app/com.xx.xxxxxxxxxxxxx-RG7tZfAu52Wrq4tU5KPo7Q==/split_lib_slice_9_apk.apk)
  4. at com.example.xxxxx.xxxxxxxxxx.ui.activities.MainActivity.onCreate(MainActivity.java:166)
  5. at android.app.Activity.performCreate(Activity.java:7458)
  6. at android.app.Activity.performCreate(Activity.java:7448)
  7. at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1286)
  8. at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3409)
  9. at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3614)
  10. at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:86)
  11. at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:108)
  12. at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:68)
  13. at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2199)
  14. at android.os.Handler.dispatchMessage(Handler.java:112)
  15. at android.os.Looper.loop(Looper.java:216)
  16. at android.app.ActivityThread.main(ActivityThread.java:7625)
  17. at java.lang.reflect.Method.invoke(Native Method)
  18. at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)
  19. at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:987)

导入module之后报错闪退

查看报错位置为onCreate 中的  

textView=(TextView)findViewById(R.id.septal_line3)加载错误

发现是module中的layout和app中的layout命名重了,都是activity_main.xml,改为不同即可

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/知新_RL/article/detail/155932?site
推荐阅读
相关标签
  

闽ICP备14008679号