java.lang.IllegalStateException: Could not execute method for android:onClick

Stack Overflow | user6694745 | 6 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    TextInputLayout.setError() throws an exception. Why and how to fix?

    Stack Overflow | 6 months ago | user6694745
    java.lang.IllegalStateException: Could not execute method for android:onClick

    Root Cause Analysis

    1. java.lang.IllegalAccessError

      tried to access method android.support.v7.widget.AppCompatDrawableManager.getPorterDuffColorFilter:()V from class android.support.design.widget.TextInputLayout

      at android.support.design.widget.TextInputLayout.updateEditTextBackground()
    2. android.support.design
      TextInputLayout.setError
      1. android.support.design.widget.TextInputLayout.updateEditTextBackground(TextInputLayout.java:700)
      2. android.support.design.widget.TextInputLayout.setError(TextInputLayout.java:592)
      2 frames
    3. com.example.testandroidsupportv7
      ActivityEditText.onClickButtonSetError
      1. com.example.testandroidsupportv7.ActivityEditText.onClickButtonSetError(ActivityEditText.java:30)
      1 frame
    4. Java RT
      Method.invoke
      1. java.lang.reflect.Method.invokeNative(Native Method)
      2. java.lang.reflect.Method.invoke(Method.java:511)
      2 frames
    5. Android v7
      AppCompatViewInflater$DeclaredOnClickListener.onClick
      1. android.support.v7.app.AppCompatViewInflater$DeclaredOnClickListener.onClick(AppCompatViewInflater.java:270)
      1 frame
    6. Android Platform
      ActivityThread.main
      1. android.view.View.performClick(View.java:4232)
      2. android.view.View$PerformClick.run(View.java:17298)
      3. android.os.Handler.handleCallback(Handler.java:615)
      4. android.os.Handler.dispatchMessage(Handler.java:92)
      5. android.os.Looper.loop(Looper.java:137)
      6. android.app.ActivityThread.main(ActivityThread.java:4921)
      6 frames
    7. Java RT
      Method.invoke
      1. java.lang.reflect.Method.invokeNative(Native Method)
      2. java.lang.reflect.Method.invoke(Method.java:511)
      2 frames
    8. Android
      ZygoteInit.main
      1. com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1027)
      2. com.android.internal.os.ZygoteInit.main(ZygoteInit.java:794)
      2 frames
    9. Android Platform
      NativeStart.main
      1. dalvik.system.NativeStart.main(Native Method)
      1 frame