Bri*_*tel 3 asp.net html-table code-behind tablerow
我在文件后面的代码中添加表。我想在其中添加标签。
<table id="tbl" runat="server">
<tr>
<th>test</th>
<td>
</td>
</tr>
</table>
Run Code Online (Sandbox Code Playgroud)
我不知道如何通过代码添加。
那么谁能告诉我如何添加标签?
HtmlTable t = tbl; //just to make it clear your table is an HtmlTable
tbl.Rows[0].Cells.Add(new HtmlTableCell("th")); //adds an emtpy cell to the first row with th tagname
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
7594 次 |
最近记录: |