Input Mask / Literals and Prompt

Blazor Input Mask - Literals and Prompt Characters

Loading Syncfusion Blazor Server Demos…

Properties


This example demonstrates how to obtain the component value with mask literals. Type alphanumeric characters in the "Product Key" input element. The typed product key will be displayed in the label element with mask literals. Choose the corresponding option from the property panel to update the Value and prompt options.

The MaskedTextBox has the EnableLiterals property that provides an option to obtain the component value with mask literals.

Configurable Options:

The property panel provides options for the following cases:

  • PromptPlaceholder - If the user does not fill all blank spaces in the mask, it will replace them in the Value property when EnableLiterals is enabled. By default, its value is an empty string.
  • PromptCharacter - It's a prompting symbol in the MaskedTextBox for the mask elements. By default, its value is underscore.
Transform your Blazor web apps today with Syncfusion® Blazor components
145+ high-performance and responsive UI components
Dedicated support
Hassle-free licensing
TRY IT FOR FREE