Fragment MyFragment not attached to Activity
I’ve found the very simple answer: isAdded(): Return true if the fragment is currently added to its activity. To avoid onPostExecute from being called when the Fragment is not attached to the Activity is to cancel the AsyncTask when pausing or stopping the Fragment. Then isAdded() would not be necessary anymore. However, it is advisable … Read more