System.Web.UI.WebControls.DataControlField.ControlStyle Property

Gets the style of any Web server controls contained by the System.Web.UI.WebControls.DataControlField object.

Syntax

[System.ComponentModel.DesignerSerializationVisibility(System.ComponentModel.DesignerSerializationVisibility.Content)]
[System.ComponentModel.DefaultValue(null)]
[System.Web.UI.PersistenceMode(System.Web.UI.PersistenceMode.InnerProperty)]
public Style ControlStyle { get; }

Value

Documentation for this section has not yet been entered.

Remarks

The DataControlField.ControlStyle property governs the appearance of any Web server controls contained by types derived from System.Web.UI.WebControls.DataControlField.

This property does not affect all derived types. The System.Web.UI.WebControls.BoundField control, which typically displays text data and contains only System.Web.UI.WebControls.TextBox controls, is only affected by the DataControlField.ControlStyle property when in DataControlRowState.Edit state. Web server controls such as System.Web.UI.WebControls.ButtonField and System.Web.UI.WebControls.CheckBoxField might be affected by the DataControlField.ControlStyle property, depending on the specific configuration of the control object instances contained by the field. For example, the System.Web.UI.WebControls.ButtonField control can be rendered as a System.Web.UI.WebControls.LinkButton, System.Web.UI.WebControls.ImageButton, or System.Web.UI.WebControls.Button object. Although a System.Web.UI.WebControls.LinkButton control is affected by font attributes of the specified System.Web.UI.WebControls.Style object, a System.Web.UI.WebControls.Button control is not.

Requirements

Namespace: System.Web.UI.WebControls
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0