Did you get this to work? I'm facing the same problem: InflateException
VinceGee opened this issue · comments
FATAL EXCEPTION: main
android.view.InflateException: Binary XML file line #23: Binary XML file line #23: Error inflating class
Caused by: android.view.InflateException: Binary XML file line #23: Error inflating class
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Constructor.newInstance0(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:334)
at android.view.LayoutInflater.createView(LayoutInflater.java:647)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:790)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:730)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:863)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:824)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:866)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:824)
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 com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:419)
at android.app.Dialog.setContentView(Dialog.java:528)
at am.appwise.components.ni.NoInternetDialog.onCreate(NoInternetDialog.java:198)
at android.app.Dialog.dispatchOnCreate(Dialog.java:403)
at android.app.Dialog.show(Dialog.java:302)
at am.appwise.components.ni.NoInternetDialog.show(NoInternetDialog.java:578)
at am.appwise.components.ni.NoInternetDialog$9.hasActiveConnection(NoInternetDialog.java:588)
at am.appwise.components.ni.Ping.onPostExecute(Ping.java:22)
at am.appwise.components.ni.Ping.onPostExecute(Ping.java:10)
at android.os.AsyncTask.finish(AsyncTask.java:695)
at android.os.AsyncTask.-wrap1(Unknown Source:0)
at android.os.AsyncTask$InternalHandler.handleMessage(AsyncTask.java:712)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6494)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807)
Caused by: java.lang.UnsupportedOperationException: Failed to resolve attribute at index 13: TypedValue{t=0x2/d=0x7f0301d0 a=-1}
compileSdkVersion 28, targetSdkVersion 28, other dependencies are running 28.0.0
Originally posted by @VinceGee in #8 (comment)
You can try this similar library: https://github.com/ImaginativeShohag/Oops-No-Internet