java.lang.RuntimeException: You have to provide a ViewHolder with a constructor which takes a view!

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 AndrazP
, 1 year ago
You have to provide a ViewHolder with a constructor which takes a view!
via GitHub by shubhamchaudhary
, 1 year ago
You have to provide a ViewHolder with a constructor which takes a view!
via Stack Overflow by orienlalxoxo orienlalxoxo
, 4 months ago
You have to provide a ViewHolder with a constructor which takes a view!
java.lang.RuntimeException: You have to provide a ViewHolder with a constructor which takes a view!
at com.mikepenz.fastadapter.items.AbstractItem$ReflectionBasedViewHolderFactory.create(AbstractItem.java:343)
at com.mikepenz.fastadapter.items.AbstractItem.getViewHolder(AbstractItem.java:284)
at com.mikepenz.fastadapter.items.AbstractItem.getViewHolder(AbstractItem.java:233)
at com.mikepenz.fastadapter.FastAdapter$OnCreateViewHolderListenerImpl.onPreCreateViewHolder(FastAdapter.java:1326)
at com.mikepenz.fastadapter.FastAdapter.onCreateViewHolder(FastAdapter.java:330)
at com.mikepenz.fastadapter.AbstractAdapter.onCreateViewHolder(AbstractAdapter.java:128)
at android.support.v7.widget.RecyclerView$Adapter.createViewHolder(RecyclerView.java:5482)
at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:4707)
at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:4617)
at android.support.v7.widget.LinearLayoutManager$LayoutState.next(LinearLayoutManager.java:1994)
at android.support.v7.widget.LinearLayoutManager.layoutChunk(LinearLayoutManager.java:1390)
at android.support.v7.widget.LinearLayoutManager.fill(LinearLayoutManager.java:1353)
at android.support.v7.widget.LinearLayoutManager.scrollBy(LinearLayoutManager.java:1180)
at android.support.v7.widget.LinearLayoutManager.scrollVerticallyBy(LinearLayoutManager.java:1031)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:788)
at android.view.Choreographer.doCallbacks(Choreographer.java:591)
at android.view.Choreographer.doFrame(Choreographer.java:559)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:774)
at android.os.Handler.handleCallback(Handler.java:808)
at android.os.Handler.dispatchMessage(Handler.java:103)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:5333)
at java.lang.reflect.Method.invokeNative(Method.java)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:824)
at dalvik.system.NativeStart.main(NativeStart.java)

Users with the same issue

You are the first who have seen this exception. Write a tip to help other users and build your expert profile.

Know the solutions? Share your knowledge to help other developers to debug faster.