New to Telerik UI for .NET MAUI? Start a free 30-day trial
.NET MAUI MaskedEntry Value
Updated on Jul 22, 2025
To set a predefined value inside the MaskedEntry, define the Value(string) property. It returns the user input without the formatting characters.
- TextMaskedEntry with
Valueproperty
Define the RadTextMaskedEntry in XAML:
xaml
<telerik:RadTextMaskedEntry x:Name="textMaskedEntry" Mask="aaaa" Value="ABCD" AutomationId="textMask"/>
Add the telerik namespace:
XAML
xmlns:telerik="clr-namespace:Telerik.Maui.Controls;assembly=Telerik.Maui.Controls"
Define the RadTextMaskedEntry in C#:
C#
this.textMaskedEntry.Value = "Test";
Add the telerik namespace:
C#
using Telerik.Maui.Controls;
Null Value Support
By default, the MaskedEntry control doesn't allow you to set null to its Value property. Instead, the null value in the NumericMaskedEntry is coerced to 0. To allow null values, you have to set the AllowNullValue property to True.
- NumericMaskedEntry with null value support
Define the control:
xaml
<telerik:RadNumericMaskedEntry x:Name="allowNullValuesTextMaskedEntry" Value="5" AllowNullValue="True" AutomationId="textMaskNullAllowed"/>
Add the namespace:
XAML
xmlns:telerik="clr-namespace:Telerik.Maui.Controls;assembly=Telerik.Maui.Controls"
For the MaskedEntry Value example, go to the SDKBrowser Demo Application and navigate to MaskedEntry -> Features category.