I am currently trying to make a form which works dynamically.
I created a flow layout panel, add button, and remove button on the form.
When I click on the add button, combo box appears inside the panel and keeps adding if I click on add button from top to bottom.
Problem is I don’t know how to remove one by one.
For example, if I added three combo box by clicking add button 3 times(say combo box 1, 2, 3), I want to remove them in order 3, 2, 1 as I click remove button.
How do I do this in C#?
Thank you very much.
Try this:
Refer to Control.ControlCollection.RemoveAt Method