您的位置:首页 > 其它

在后台得到前台元素,给元素改变属性值或添加属性

2012-03-03 14:10 337 查看
View Code

如要在后台改变<tr>标签的属性style
<tr  style ="display:none"  runat ="server" id="Tr">
<td>
<asp:Label ID="Name3" runat="server" Text="Label"></asp:Label></td>
<td>
</tr>

后台代码:
this.Tr.Attributes["style"] = "";//将style属性改为空
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: