Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via GitHub by studentapptdt
, 1 year ago
android.widget.FrameLayout$LayoutParams cannot be cast to android.support.v7.widget.RecyclerView$LayoutParams
ava.lang.ClassCastException: android.widget.FrameLayout$LayoutParams cannot be cast to android.support.v7.widget.RecyclerView$LayoutParams	at android.support.v7.widget.RecyclerView.getChildViewHolderInt(RecyclerView.java:3979)	at android.support.v7.widget.RecyclerView$LayoutManager.removeAndRecycleScrapInt(RecyclerView.java:7719)	at android.support.v7.widget.RecyclerView.dispatchLayoutStep3(RecyclerView.java:3388)	at android.support.v7.widget.RecyclerView.dispatchLayout(RecyclerView.java:3135)	at android.support.v7.widget.RecyclerView.onLayout(RecyclerView.java:3568)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:344)	at android.widget.FrameLayout.onLayout(FrameLayout.java:281)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1742)	at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1585)	at android.widget.LinearLayout.onLayout(LinearLayout.java:1494)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.RelativeLayout.onLayout(RelativeLayout.java:1080)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:344)	at android.widget.FrameLayout.onLayout(FrameLayout.java:281)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.support.v4.view.ViewPager.onLayout(ViewPager.java:1767)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.support.design.widget.HeaderScrollingViewBehavior.layoutChild(HeaderScrollingViewBehavior.java:131)	at android.support.design.widget.ViewOffsetBehavior.onLayoutChild(ViewOffsetBehavior.java:42)	at android.support.design.widget.AppBarLayout$ScrollingViewBehavior.onLayoutChild(AppBarLayout.java:1364)	at android.support.design.widget.CoordinatorLayout.onLayout(CoordinatorLayout.java:852)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.RelativeLayout.onLayout(RelativeLayout.java:1080)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:344)	at android.widget.FrameLayout.onLayout(FrameLayout.java:281)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1742)	at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1585)	at android.widget.LinearLayout.onLayout(LinearLayout.java:1494)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:344)	at android.widget.FrameLayout.onLayout(FrameLayout.java:281)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1742)	at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1585)	at android.widget.LinearLayout.onLayout(LinearLayout.java:1494)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:344)	at android.widget.FrameLayout.onLayout(FrameLayout.java:281)	at com.android.internal.policy.PhoneWindow$DecorView.onLayout(PhoneWindow.java:3193)	at android.view.View.layout(View.java:17938)	at android.view.ViewGroup.layout(ViewGroup.java:5812)	at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:2666)