Skip to main content

DxDateTimeMaskProperties Class

Defines date-time mask settings.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v23.2.dll

NuGet Package: DevExpress.Blazor


public class DxDateTimeMaskProperties :


You can apply date-time input masks to the Date Edit, Time Edit, and Masked Input components. Date-time masks allow users to enter only date and/or time values. Users can navigate between mask sections (such as months, days, and hours) and increase or decrease section values with the Up and Down arrow keys, and the mouse wheel.

Date-Time Masks

Run Demo: Date Edit Run Demo: Time Edit Run Demo: Masked Input

Choose a mask from a number of predefined patterns or use a standard or custom format string. Assign a mask pattern to an editor’s Mask property to apply the mask to the editor. Add the DxDateTimeMaskProperties component to the editor’s markup to customize mask-related settings:

@using System.Globalization

<DxDateEdit @bind-Date="@date" 
    <DxDateTimeMaskProperties CaretMode="@MaskCaretMode.Advancing"
                              InvalidInputNotificationText="The date is invalid."
                              UpdateNextSectionOnCycleChange="true" />

@code {
    DateTime date { get; set; } = DateTime.Now;
    CultureInfo Culture = new CultureInfo("fr-FR");

Refer to the following topic for more information: Mask Settings.


See Also