我是靠谱客的博主 雪白小丸子,最近开发中收集的这篇文章主要介绍编写的android软件闪退,写安卓时程序一直闪退,觉得挺不错的,现在分享给大家,希望可以做个参考。

概述

08-16 13:14:13.436 17394-17394/? E/AndroidRuntime: FATAL EXCEPTION: main

Process: bjfu.it.note, PID: 17394

java.lang.RuntimeException: Unable to start activity ComponentInfo{bjfu.it.note/bjfu.it.note.MainActivity}: android.view.InflateException: Binary XML file line #38: Binary XML file line #38: Error inflating class com.google.android.material.floatingactionbutton.FloatingActionButton

at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)

at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)

at android.app.ActivityThread.-wrap11(ActivityThread.java)

at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)

at android.os.Handler.dispatchMessage(Handler.java:102)

at android.os.Looper.loop(Looper.java:148)

at android.app.ActivityThread.main(ActivityThread.java:5417)

at java.lang.reflect.Method.invoke(Native Method)

at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)

at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

Caused by: android.view.InflateException: Binary XML file line #38: Binary XML file line #38: Error inflating class com.google.android.material.floatingactionbutton.FloatingActionButton

at android.view.LayoutInflater.inflate(LayoutInflater.java:539)

at android.view.LayoutInflater.inflate(LayoutInflater.java:423)

at android.view.LayoutInflater.inflate(LayoutInflater.java:374)

at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:469)

at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:140)

at bjfu.it.note.MainActivity.onCreate(MainActivity.java:32)

at android.app.Activity.performCreate(Activity.java:6237)

at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)

at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)

at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)

at android.app.ActivityThread.-wrap11(ActivityThread.java)

at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)

at android.os.Handler.dispatchMessage(Handler.java:102)

at android.os.Looper.loop(Looper.java:148)

at android.app.ActivityThread.main(ActivityThread.java:5417)

at java.lang.reflect.Method.invoke(Native Method)

at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)

at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

Caused by: android.view.InflateException: Binary XML file line #38: Error inflating class com.google.android.material.floatingactionbutton.FloatingActionButton

at android.view.LayoutInflater.createView(LayoutInflater.java:645)

at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:764)

at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:704)

at android.view.LayoutInflater.rInflate(LayoutInflater.java:835)

at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:798)

at android.view.LayoutInflater.inflate(LayoutInflater.java:515)

at android.view.LayoutInflater.inflate(LayoutInflater.java:423)

at android.view.LayoutInflater.inflate(LayoutInflater.java:374)

at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:469)

at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:140)

at bjfu.it.note.MainActivity.onCreate(MainActivity.java:32)

at android.app.Activity.performCreate(Activity.java:6237)

at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)

at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)

at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)

at android.app.ActivityThread.-wrap11(ActivityThread.java)

at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)

at android.os.Handler.dispatchMessage(Handler.java:102)

at android.os.Looper.loop(Looper.java:148)

at android.app.ActivityThread.main(ActivityThread.java:5417)

at java.lang.reflect.Method.invoke(Native Method)

at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)

at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

Caused by: java.lang.reflect.InvocationTargetException

at java.lang.reflect.Constructor.newInstance(Native Method)

at android.view.LayoutInflater.createView(LayoutInflater.java:619)

at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:764)

at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:704)

at android.view.LayoutInflater.rInflate(LayoutInflater.java:835)

at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:798)

at android.view.LayoutInflater.inflate(LayoutInflater.java:515)

at android.view.LayoutInflater.inflate(LayoutInflater.java:423)

at android.view.LayoutInflater.inflate(LayoutInflater.java:374)

at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:469)

at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:140)

at bjfu.it.note.MainActivity.onCreate(MainActivity.java:32)

at android.app.Activity.performCreate(Activity.java:6237)

at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)

at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)

at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)

at android.app.ActivityThread.-wrap11(ActivityThread.java)

at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)

at android.os.Handler.dispatchMessage(Handler.java:102)

at android.os.Looper.loop(Looper.java:148)

at android.app.ActivityThread.main(ActivityThread.java:5417)

at java.lang.reflect.Method.invoke(Native Method)

at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)

at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

Caused by: android.content.res.Resources$NotFoundException: Resource “bjfu.it.note:drawable/ic_add_white_24dp” (7f070064) is not a Drawable (color or path): TypedValue{t=0x1/d=0x7f070064 a=-1 r=0x7f070064}

at android.content.res.Resources.loadDrawableForCookie(Resources.java:2602)

at android.content.res.Resources.loadDrawable(Resources.java:2540)

at android.content.res.TypedArray.getDrawable(TypedArray.java:870)

at android.widget.ImageView.(ImageView.java:152)

at android.widget.ImageButton.(ImageButton.java:84)

at android.widget.ImageButton.(ImageButton.java:80)

at com.google.android.material.internal.VisibilityAwareImageButton.(VisibilityAwareImageButton.java:45)

at com.google.android.material.floatingactionbutton.FloatingActionButton.(FloatingActionButton.java:192)

at com.google.android.material.floatingactionbutton.FloatingActionButton.(FloatingActionButton.java:188)

at java.lang.reflect.Constructor.newInstance(Native Method)

at android.view.LayoutInflater.createView(LayoutInflater.java:619)

at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:764)

at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:704)

at android.view.LayoutInflater.rInflate(LayoutInflater.java:835)

at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:798)

at android.view.LayoutInflater.inflate(LayoutInflater.java:515)

at android.view.LayoutInflater.inflate(LayoutInflater.java:423)

at android.view.LayoutInflater.inflate(LayoutInflater.java:374)

at androidx.appcompat.app.AppCompatDelegateImpl.setContentView(AppCompatDelegateImpl.java:469)

at androidx.appcompat.app.AppCompatActivity.setContentView(AppCompatActivity.java:140)

at bjfu.it.note.MainActivity.onCreate(MainActivity.java:32)

at android.app.Activity.performCreate(Activity.java:6237)

at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)

at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)

at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)

at android.app.ActivityThread.-wrap11(ActivityThread.java)

at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)

at android.os.Handler.dispatchMessage(Handler.java:102)

at android.os.Looper.loop(Looper.java:148)

at android.app.ActivityThread.main(ActivityThread.java:5417)

at java.lang.reflect.Method.invoke(Native Method)

at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)

at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

回答

Unable to start activity ComponentInfo{bjfu.it.note/bjfu.it.note.MainActivity}: android.view.InflateException: Binary XML file line #38: Binary XML file line #38: Error inflating class com.google.android.material.floatingactionbutton.FloatingActionButton

答案就在这里

最后

以上就是雪白小丸子为你收集整理的编写的android软件闪退,写安卓时程序一直闪退的全部内容,希望文章能够帮你解决编写的android软件闪退,写安卓时程序一直闪退所遇到的程序开发问题。

如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(74)

评论列表共有 0 条评论

立即
投稿
返回
顶部