Back to Devexpress

TimeSpanMask Class

blazor-devexpress-dot-blazor-9101af82.md

latest1.7 KB
Original Source

TimeSpanMask Class

Defines built-in patterns for time span masks.

Namespace : DevExpress.Blazor

Assembly : DevExpress.Blazor.v25.2.dll

NuGet Package : DevExpress.Blazor

Declaration

csharp
public static class TimeSpanMask

Remarks

Use properties of the TimeSpanMask class to apply commonly used time span mask patterns to the Masked Input component. Each property is a wrapper for the corresponding standard time span format string. This technique simplifies the setup process.

razor
<DxMaskedInput @bind-Value="time"
               Mask="@TimeSpanMask.GeneralShortFormat" />
@code {
    TimeSpan time = new TimeSpan(5, 16, 30, 15, 7);
}

The appearance of the GeneralShortFormat and GeneralLongFormat mask patterns include the fractional seconds separator that depends on the current culture. Users can change the regional format in the SettingsTime & LanguageRegion system dialog. To change the mask culture programmatically, use the Culture property.

Inheritance

Object TimeSpanMask

See Also

TimeSpanMask Members

DevExpress.Blazor Namespace