Validation Message

The Telerik MaskedEntry for .NET MAUI provides a built-in validation message. If the user is entering an input that does not match the mask requirements, the MaskedEntry will display an error message.

Default Error Message

The MaskedEntry supports a default validation error message that is based on the used Masked Type:

  • EmailMaskedEntry—Supports the E-Mail is not valid error message.

  • RegexMaskedEntry—Supports the Input does not match the regex error message.

Custom Error Message

To customize the default validation error message, use the ValidationErrorMessage(string) property.

Custom Validation Error Message for the RadEmailMaskedEntry

<telerik:RadEmailMaskedEntry x:Name="emailMaskedEntry" ValidationErrorMessage="Please, enter a valid e-mail adress"/>

Custom Validation Error Message for the RadRegexMaskedEntry

<telerik:RadRegexMaskedEntry x:Name="regexMaskedEntry" Mask="^[a-z]$" PlaceholderText="^[a-z]$" ValidationErrorMessage="Only one symbol can be entered" />

For the ValidationErrorMessage example, refer to the MaskedEntry/Features folder of the SDK .NET MAUI Application.

See Also

In this article
Not finding the help you need?