Dynamic Fragments in Android

前端 未结 1 702
予麋鹿
予麋鹿 2021-01-18 11:33

Is it possible to create fragments dynamically to generate a layout containing multiple fragments something like in a grid view. Currently, i m only able to load multiple fr

相关标签:
1条回答
  • 2021-01-18 12:08

    Absolutely! Check out the Android Developers guide to Fragments. Be sure the see the second bullet point here, as well as the "Performing Fragment Transactions" section: http://developer.android.com/guide/topics/fundamentals/fragments.html#Adding

    Additionally you can see your options for managing Fragments in this class: http://developer.android.com/reference/android/app/FragmentTransaction.html

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