How can display recycler view using fragment in android

前端 未结 2 534
野趣味
野趣味 2021-01-29 14:22

I want to display recycler view inside fragment but i am getting java.lang.NullPointerException: Attempt to invoke virtual method \'boolean android.support.v7.widget.Rec

2条回答
  •  旧时难觅i
    2021-01-29 14:54

    You are creating a view (in the first line) and you are ignoring it and returning something else.

    You should do this :

    return(rootview)
    

提交回复
热议问题