Tab

SpinEditProperties.NumberFormat Property

Gets or sets the format of the spin editor's displayed number.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v20.2.dll

Declaration

[DefaultValue(SpinEditNumberFormat.Number)]
public SpinEditNumberFormat NumberFormat { get; set; }

Property Value

Type Default Description
SpinEditNumberFormat

Number

A SpinEditNumberFormat enumeration value.

Available values:

Name Description
Custom

The displayed number is represented using a custom format pattern specified via the SpinEditProperties.DisplayFormatString property.

Currency

The displayed number is represented using a format pattern for a currency value (which is associated with the 'c' format character).

Percent

The displayed number is represented using a format pattern for a percentage value (which is associated with the '{0}%' custom format string).

Number

The displayed number is represented using a general format pattern for a number value (which is associated with the 'g' format character).

Remarks

Changing the NumberFormat property sets the value of the SpinEditProperties.DisplayFormatString property to the corresponding format string.

If the NumberFormat property is set to SpinEditNumberFormat.Custom, the SpinEditProperties.DisplayFormatString property specifies the pattern used to format the editor's value for display purposes.

If an editor is used for inplace editing within a complex data control (such as the ASPxGridView or ASPxTreeList), the TextEditProperties.DisplayFormatInEditMode property can additionally be used to apply the format provided by the SpinEditProperties.DisplayFormatString property to the editor value in the data control's edit mode.

See Also