I have one Activity. The Activity has two Fragments.
Fragment A is Menu. Fragment B is Detail.
I try to Make other Fragment C
If you are in the fragment itself, you need to call this. Your fragment needs to be the fragment that is being called. Enter code:
getFragmentManager().beginTransaction().remove(yourFragment).commitAllowingStateLoss();
or if you are using supportLib, then you need to call:
getSupportFragmentManager().beginTransaction().remove(yourFragment).commitAllowingStateLoss();