How to call fragment from fragment?

后端 未结 2 1831
太阳男子
太阳男子 2020-12-09 21:21

I use the fragment, and i open another view in the same fragment it\'s open properly, But the problem is, I can\'t get that how get back to the fir

相关标签:
2条回答
  • 2020-12-09 22:01

    I use Fragment on android3.0(Tab app) in that i got this as worked.

    Fragment duedateFrag = new DuedateFrag(true);
    FragmentTransaction ft  = getFragmentManager().beginTransaction();
    ft.replace(R.id.main_tasklistdetail_lay, duedateFrag);
    ft.addToBackStack(null);
    ft.commit();
    
    0 讨论(0)
  • 2020-12-09 22:15

    You can use setTargetFragment. An example is available here

    0 讨论(0)
提交回复
热议问题