I am developing an app that does some calculation. It consists of a horizontal linearLayout
and each Layout has 2 edit text and and a spinner. I want to make it in such a way that the user can add layouts with button click when he needs to add more details.
In my XML I set android:visibility="gone"
and in Java I set the onClick
method to make the "gone" linear layout to view.VISIBLE
. It worked but it makes all the linear layouts appear once I click the + button. I want them to appear one after the other (one appear and others remain "gone" until I click the button again)