Android ViewPager and fragments design
问题 I have a ViewPager with 3 fragments into it. Everything works fine with two of them. The problem is with the third pager This one is a TabHost , in which there is one fragment in each tab. But I've read that it's is not possible to put a Tabhost inside a Fragment. Nested fragments are forbidden. Anyone has any idea of what can I do for resolving my problem? Any alternatives? 回答1: You can refer the code as mentioned in this problem it will work as per your design.Plese see 回答2: This is what i