System.Web.UI.WebControls.BoundField.ApplyFormatInEditMode Property

Gets or sets a value indicating whether the formatting string specified by the BoundField.DataFormatString property is applied to field values when the data-bound control that contains the System.Web.UI.WebControls.BoundField object is in edit mode.

Syntax

[System.ComponentModel.DefaultValue(false)]
public virtual bool ApplyFormatInEditMode { set; get; }

Value

Documentation for this section has not yet been entered.

Remarks

Data-bound controls (such as System.Web.UI.WebControls.DetailsView, System.Web.UI.WebControls.FormView, and System.Web.UI.WebControls.GridView) have different display modes that allow the user to read, edit, or insert records. By default, the formatting string specified by the BoundField.DataFormatString property is applied to field values only when the data-bound control is in read-only mode. To apply the formatting string to values displayed while the data-bound control is in edit mode, set the BoundField.ApplyFormatInEditMode property to true.

Note:

A System.Web.UI.WebControls.BoundField object does not automatically remove the formatting when the field is updated in the data source. If you do not want the formatting as part of the value stored, you will need to remove the formatting programmatically.

Requirements

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