Skip to content Skip to sidebar Skip to footer

"no Adapter Attached; Skipping Layout" On A Fragment

public class WorkFragment extends Fragment { List items = new ArrayList<>(); @Override public void onCreate(Bundle savedInstanceState) { super.onCre

Solution 1:

the problem is mostly this line

return inflater.inflate(R.layout.fragment_work, container, false);

you should have

return rootView

With the first return you are inflating a new totally different view hierarchy, starting from fragment_work.xml, from the one which has an the RecyclerView correctly set up.

Post a Comment for ""no Adapter Attached; Skipping Layout" On A Fragment"