Answer the question
In order to leave comments, you need to log in
How to properly remove a View from a container?
Good!
The LinearLayout contains a View with a Button, when you click on this Button View should be deleted, I suppose the child should not delete itself, how is this done correctly in java?
Answer the question
In order to leave comments, you need to log in
LinearLayout.removeView(childView); in onClickListener'e if needed. The listener is not part of the button itself, so it won't "delete itself".
PS I can see directly from the questions that you are going further and further the wrong way.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question