I am trying to design a layout so that I can change the views inside the layout dynamically.
My first thought was to make them layouts set to “GONE”, and although that worked fine, it was a pain to make any adjustments.
What I would like to do is to have the layouts described as separate layout files, and then filled into the main view by my code.
Could you help me understand how to to this? Thanks.
It’s better to place those layout into different files and add on your xml file using include tag….For example
and use the layout visibility properties on included layout files by getting references on your code.