System.Web.UI.WebControls Namespace Style Class
Sets or retrieves the border color of a Web control.
Inline |
<asp:control BorderColor = strColor ... > |
Script |
Style.BorderColor [ = strColor ] |
strColor |
A System.Drawing.Color that represents the border color of the control, using any of the standard .NET color identifiers. See Color Table. |
This property is read/write and returns an empty string if not set.
BorderColor is used to specify the border color of a Web server control. This property is set using a System.Drawing.Color object, the possible range of values of which are specified in this workshop's Color Table.
Note that this property will render only for certain controls.
In general, only controls that render as an HTML <table> or <div> element ( block objects ) can display a border color, such as Table, Panel, DataGrid, Calendar, etc.
It will also work for list controls that have their RepeatLayout property set to Table, such as the CheckBoxList, RadioButtonList and DataList.
This property, however, is rendered as the bordercolor attribute, which is not part of the HTML 3.2 standard. BorderColor works for Internet Explorer version 3 and later, but not for most other browsers.
NOTE: The BorderStyle and BorderWidth properties of the control must be set in order for this property to have any effect.
Style Members Base Web Control Properties