java.lang.ClassCastException

android.widget.LinearLayout$LayoutParams cannot be cast to android.widget.FrameLayout$LayoutParams

Solutions on the web19142

  • via GitHub by lasic01
    , 4 months ago
    android.widget.LinearLayout$LayoutParams cannot be cast to android.widget.FrameLayout$LayoutParams
  • android.widget.FrameLayout$LayoutParams cannot be cast to android.widget.LinearLayout$LayoutParams
  • android.widget.FrameLayout$LayoutParams cannot be cast to android.widget.LinearLayout$LayoutParams
  • Stack trace

    • java.lang.ClassCastException: android.widget.LinearLayout$LayoutParams cannot be cast to android.widget.FrameLayout$LayoutParams at android.widget.FrameLayout.onMeasure(FrameLayout.java:203) at android.view.View.measure(View.java:20151) at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6328) at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1464) at android.widget.LinearLayout.measureVertical(LinearLayout.java:747) at android.widget.LinearLayout.onMeasure(LinearLayout.java:629) at android.view.View.measure(View.java:20151) at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6328) at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1464) at android.widget.LinearLayout.measureVertical(LinearLayout.java:747) at android.widget.LinearLayout.onMeasure(LinearLayout.java:629) at android.view.View.measure(View.java:20151) at android.widget.RelativeLayout.measureChildHorizontal(RelativeLayout.java:716) at android.widget.RelativeLayout.onMeasure(RelativeLayout.java:462) at android.view.View.measure(View.java:20151) at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6328) at android.widget.FrameLayout.onMeasure(FrameLayout.java:194) at android.support.v7.widget.ContentFrameLayout.onMeasure(ContentFrameLayout.java:135) at android.view.View.measure(View.java:20151) at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6328) at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1464) at android.widget.LinearLayout.measureVertical(LinearLayout.java:747) at android.widget.LinearLayout.onMeasure(LinearLayout.java:629) at android.view.View.measure(View.java:20151) at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6328) at android.widget.FrameLayout.onMeasure(FrameLayout.java:194) at android.view.View.measure(View.java:20151) at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6328) at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1464) at android.widget.LinearLayout.measureVertical(LinearLayout.java:747) at android.widget.LinearLayout.onMeasure(LinearLayout.java:629) at android.view.View.measure(View.java:20151) at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:6328) at android.widget.FrameLayout.onMeasure(FrameLayout.java:194) at com.android.internal.policy.PhoneWindow$DecorView.onMeasure(PhoneWindow.java:3158) at android.view.View.measure(View.java:20151) at android.view.ViewRootImpl.performMeasure(ViewRootImpl.java:2594) at android.view.ViewRootImpl.measureHierarchy(ViewRootImpl.java:1549) at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1841) at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1437) at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:7397) at android.view.Choreographer$CallbackRecord.run(Choreographer.java:920) at android.view.Choreographer.doCallbacks(Choreographer.java:695) at android.view.Choreographer.doFrame(Choreographer.java:631) at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:906) at android.os.Handler.handleCallback(Handler.java:739) at android.os.Handler.dispatchMessage(Handler.java:95) at android.os.Looper.loop(Looper.java:158) at android.app.ActivityThread.main(ActivityThread.java:7224) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    3 times, 3 months ago
    Unknown user
    Once, 11 months ago
    Once, 1 year ago
    11 times, 7 months ago
    Unknown user
    Once, 1 year ago
    7 more bugmates