System.Web.UI.WebControls.TableCellCollection.Clear Method

Removes all System.Web.UI.WebControls.TableCell objects from the System.Web.UI.WebControls.TableCellCollection.

Syntax

public void Clear ()

Remarks

Use this method to remove all System.Web.UI.WebControls.TableCell objects from the System.Web.UI.WebControls.TableCellCollection and set the TableCellCollection.Count property to 0.

Note:

This method removes the System.Web.UI.WebControls.TableCell objects from the System.Web.UI.WebControls.TableCellCollection, but it does not remove the System.Web.UI.WebControls.TableRow from the System.Web.UI.WebControls.Table control. Be sure to also remove the System.Web.UI.WebControls.TableRow if you want to completely remove a row from the table.

Requirements

Namespace: System.Web.UI.WebControls
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0