Answer the question
In order to leave comments, you need to log in
Why is onCreateView not executed after the fragment is added to the activity?
Here I am adding a fragment to the activity container:
fragmentManager.beginTransaction()
.add(R.id.preview, previewFragment)
.commit();
Log.d("app", "2");
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
View v = inflater.inflate(R.layout.frament_photo_preview, container, false);
Log.d("app", "0");
return v;
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question