
728
|
Chapter 39: The System.Web.UI.HtmlControls Namespace
This is the Title of the Book, eMatter Edition
Copyright © 2008 O’Reilly & Associates, Inc. All rights reserved.
HtmlTable
System.Web.UI.HtmlControls (system.web.dll)
disposable
class
This class provides a powerful way to access the HTML <table> element. You can also
use it to dynamically generate an HTML table by adding HtmlTableRow objects to the Rows
collection and adding HtmlTableCell objects to each row. Programmatically created tables
must be recreated with every postback.
Most other properties for the HtmlTable class correspond to formatting options,
including the background color (BgColor), alignment (Align), and dimensions (Height and
Width). You can also set values in pixels for the width of the border around the table
(Border), the spacing between cells (CellSpacing), and the spacing between cell borders and
content (CellPadding).
Hierarchy
System.Object ➝ System.Web.UI.Control(System.ComponentModel.IComponent, System.
IDisposable, System.Web.UI.IParserAccessor, System.Web.UI.IDataBindingsAccessor)
➝
HtmlControl(System.Web.UI.IAttributeAccessor) ➝ HtmlContainerControl ➝ HtmlTable
HtmlTableCell
System.Web.UI.HtmlControls (system.web.dll)
disposable
class
This class represents individual <td> (table data) and <th> (table header) elements
contained in an HTML table row. The InnerHtml and InnerText properties allow you to
access the content ...