Search code examples
androidfragmenttransactionfragment-tab-hostnavigation-drawer

How to communicate with fragments in TabHost Activity


I am using a Navigation Drawer Activity inside that I have let say xyz Fragment , inside xyz fragment I have FragmentTabHost . Now I want to change Fragment in FragmentTabHost onClick on a button from a fragment in FragmentTabHost.


Solution

  • You should check this code

    Which is part of the official google sample for using a Navigation Drawer with Fragments project.