When I called another fragment, ViewPager of first fragment is not removed. I have spent 2 days on it but didn't get it. I will be very thankful if some one will help me.
FragmentManager fragmentManager = getFragmentManager();
Fragment fragment=new SecondPage(urlToSecondPageStory,storyCategoryContainer.get(position));
Bundle bundle = new Bundle();
bundle.putString("imageurl",imageUrl);
fragment.setArguments(bundle);
FragmentTransaction transaction=fragmentManager.beginTransaction();
transaction.replace(android.R.id.content,fragment);
// transaction.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_OPEN);
//transaction.addToBackStack(null);
transaction.commit();