System.Web.UI Namespace ControlCollection Class
Removes the specified control from a ControlCollection.
[ VB ] Public Sub Remove ( _ ByVal child As Control _ ) [ C# ] public void Remove ( Control child ); [ C++ ] public: void Remove ( Control* child ); [ JScript ] public function Remove ( child : Control );
Use this method to remove the specified Control from the parent server control's ControlCollection object.
To remove a Control at a specific location in the collection, use the RemoveAt method.
The following example demonstrates how to use the Remove method to programmatically remove a control from a ControlCollection.
// locate the control to remove Control control = myControl.Controls [ 0 ]; // remove the control from the Controls collection myControl.Controls.Remove ( control );
' locate the control to remove Dim control As Control = myControl.Controls ( 0 ) ' remove the control from the Controls collection myControl.Controls.Remove ( control )
ControlCollection Members Controls.RemoveAt Controls.Clear Controls.Add Controls.AddAt
© 2000-2010 Rey Nuñez All rights reserved.If you have any question, comment or suggestion about this site, please send us a note
You can help support asp.net.ph