Skip to main content
A newer version of this page is available. .

MaskProperties.UseMaskAsDisplayFormat Property

Gets or sets whether display values are still formatted using the mask when the editor is not focused.

Namespace: DevExpress.XtraEditors.Mask

Assembly: DevExpress.XtraEditors.v19.2.dll

Declaration

public virtual bool UseMaskAsDisplayFormat { get; set; }

Property Value

Type Default Description
Boolean **false**

true if the mask settings are used to format display values when the editor is not focused; false if the RepositoryItem.DisplayFormat object’s settings are used instead.

Remarks

You can set the UseMaskAsDisplayFormat property to true to use the current mask settings to form the editor’s display text when the editor is not focused. As a result the editor’s text in edit and display mode will be identical.

If this property is set to false the editor’s display text is formed according to the settings provided by the RepositoryItem.DisplayFormat property.

If the editor’s MaskProperties.MaskType property is set to MaskType.None the UseMaskAsDisplayFormat property is ignored. In this case, the RepositoryItem.DisplayFormat property’s settings are used to format display values.

The following code snippets (auto-collected from DevExpress Examples) contain references to the UseMaskAsDisplayFormat property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also