ASP.NET TableRow TableSection 屬性


TableRow 控件 TableRow 控件

定義和用法

TableSection 屬性用於設置或返回 Table 控件中的 TableRow 對象的位置。

使用 TableSection 屬性來獲取或設置在 Table 控件中放置 TableRow 對象的位置。

語法

<asp:TableRow TableSection="section" runat="server">
Some Content
</asp:TableRow>
 
屬性 描述
section 規定該行所屬的表格部分。

可能的值:

  • TableHeader - 表頭行
  • TableBody - 默認。表的正文
  • TableFooter - 註腳行


實例

下麵的實例設置了 TableRow 控件的 TableSection 屬性:

<form runat="server">
<asp:table id="Table1" runat="server" GridLines="Both">

<asp:TableRow TableSection="TableHeader">
<asp:TableCell>Header</asp:TableCell>
</asp:TableRow>

</asp:table>
</form>


TableRow 控件 TableRow 控件