RepositoryItemTextEdit.Mask Property

Provides access to the editor's input mask.

Namespace: DevExpress.XtraEditors.Repository

Assembly: DevExpress.XtraEditors.v20.1.dll


public virtual MaskProperties Mask { get; }
Public Overridable ReadOnly Property Mask As MaskProperties

Property Value

Type Description

A MaskProperties object that comprises the editor's mask settings.


A mask allows you to restrict user input. If a mask is applied, the editor allows the user to enter only the text that fits the mask expression. Use the MaskProperties.EditMask property to specify the mask expression and the MaskProperties.MaskType property to specify how to parse the expression. See Input Mask for more information.

The code below shows how to customize input in a date-time column.

RepositoryItemTextEdit textEdit = new RepositoryItemTextEdit();
textEdit.Mask.MaskType = DevExpress.XtraEditors.Mask.MaskType.DateTime;
textEdit.Mask.EditMask = "yyyy-MMM-d, HH:mm:ss ";
colOrderDate.ColumnEdit = textEdit;

To disable masked mode, set the MaskProperties.MaskType property to None.


The following editors do not support editing in masked mode: LookUpEdit, GridLookUpEdit, MemoEdit, MemoExEdit, and ImageComboBoxEdit.

See Also