Base Web Server Control Properties
The properties listed in the following table apply to all Web server controls that derive from the WebControl class. Web server controls that do not inherit from the WebControl class include Literal, PlaceHolder, Repeater, and Xml.
Properties
The control's keyboard shortcut key (AccessKey). This property specifies a single letter or number that the user can press while pressing ALT. For example, specify "K" if you want the user to press ALT+K to access the control. Shortcut keys are supported only in Microsoft Internet Explorer 4.0 and later versions. |
|||
The collection of additional attributes on the control not defined by a public property, but that should also be rendered. Any attribute that is not defined by the Web server control is added to this collection. This allows you to use an HTML attribute that is not directly supported by the control.
|
|||
The background color of the control. The BackColor property can be set using standard HTML color identifiers: the name of a color ("black" or "red") or an RGB value expressed in hexadecimal format ("#ffffff"). |
|||
The border color of the control. The BorderColor property can be set using standard HTML color identifiers: the name of a color ("black" or "red") or an RGB value expressed in hexadecimal format ("#ffffff"). |
|||
The width of the control's border (if any) in pixels.
|
|||
The control's border style, if any. The possible values are:
|
|||
The cascading style sheets (CSS) class to assign to the control. |
|||
A collection of text attributes that are rendered as a CSS style attribute on the outer tag of the control.
Some controls support style objects that allow you to apply style properties to individual elements of the control. Those properties override any settings you make using the Style property. |
|||
Makes the control functional when this property is set to true (the default). Disables the control when this property is set to false.
|
|||
Enables view state persistence for the control when this property is set to true (the default). Disables view state persistence for this control when this property is set to false. |
|||
Enables themes for the control when this property is set to true (the default). Disables themes for this control when this property is set to false. |
|||
Provides font information for the Web server control that you are declaring. This property includes subproperties that you can declare using the property-subproperty syntax in the opening tag of a Web server control element. For example, you can make a Web server control's text bold by including the Font-Bold attribute in its opening tag. |
|||
The foreground color of the control.
|
|||
The control's height.
|
|||
The skin to apply to the control. |
|||
The control's position in the tab order. If this property is not set, the control's position index is 0. Controls with the same tab index can be tabbed to according to the order in which they are declared in the Web page.
|
|||
The text that appears when the user positions the mouse pointer over a control.
|
|||
The fixed width of the control. The possible units are:
For example, to declaratively set a width of 100 expressed in points would be
|