TUTORIALBackendFETCHED
ASP.NET Style 属性
ASP.NET Style 属性 Web 控件标准属性参考手册 定义和用法 Style 属性用于向控件设置或返回内联的 CSS 样式。 语法 <asp:webcontrol id='id' Style='style' runat='server' /> 属性 描述 style 字符串,规定内联样式表的 CSS 样式。..
Updated 7/16/2026
Tutorial detail pages default to noindex.
ASP.NET Style 属性
Web 控件标准属性参考手册
定义和用法
Style 属性用于向控件设置或返回内联的 CSS 样式。
语法
<asp:webcontrol id="id" Style="style" runat="server" />
| 属性 | 描述 |
|---|---|
| style | 字符串,规定内联样式表的 CSS 样式。 |
实例
下面的实例设置 Button 控件的 CSS 样式:
<form runat="server">
<asp:Button id="Button" Text="Submit" runat="server"
Style="font: 12pt Verdana;font-weight:700;color:orange;" />
</form>
<asp:Button id="Button" Text="Submit" runat="server"
Style="font: 12pt Verdana;font-weight:700;color:orange;" />
</form>
演示实例 »
Web 控件标准属性参考手册