Hi I am developing android application in which I am using I am using single Activity and 3 fragments. So consider I have 3 fragments A B C. When I switch from A to
Activity
Try to use the replace method instead add on the FragmentTransaction. This work for me:
replace
add
FragmentTransaction
FragmentTransaction ft = activity.getSupportFragmentManager().beginTransaction(); ft.replace(R.id.fragment_container, fragment); ft.addToBackStack(null); ft.commit();