S Stanl3yCZ Member Feb 18, 2008 #1 Is it possible to remove some control in runtime? I need to remove it, not just make it invisible. Thanks.
Is it possible to remove some control in runtime? I need to remove it, not just make it invisible. Thanks.
W willisgt Active Member Licensed User Feb 18, 2008 #2 You should dispose of the control using one of two methods: 1. If you created the control in the designer and know the name, you can dispose of it in this manner: Textbox1.Dispose 2. If you create the control dynamically, you'll have to keep track of the name of the control until you want to dispose of it: AddLabel( formName, controlName, left, top, width, height, text ) ... Control( controlName ).Dispose Gary
You should dispose of the control using one of two methods: 1. If you created the control in the designer and know the name, you can dispose of it in this manner: Textbox1.Dispose 2. If you create the control dynamically, you'll have to keep track of the name of the control until you want to dispose of it: AddLabel( formName, controlName, left, top, width, height, text ) ... Control( controlName ).Dispose Gary