This documentation is archived and is not being maintained.

Form.ControlCollection.Remove Method

Removes a control from the form.

[Visual Basic]
Overrides Public Sub Remove( _
   ByVal value As Control _
public override void Remove(
 Control value
public: void Remove(
 Control* value
public override function Remove(
   value : Control


A Control to remove from the form.


You can use this method to remove controls that you no longer need in your form. If you want to display a control after it is removed, you will need to add the control back to the form using the Add method. To have a control remain on the form but not displayed, use the Visible property of the control.


Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

Form.ControlCollection Class | Form.ControlCollection Members | System.Windows.Forms Namespace | Add