New to Kendo UI for Angular? Start a free 30-day trial

Value

The MaskedTextBox enables you to format its masked (visible) value by setting its value property.

The mask-formatting configuration is based on the following properties:

  • maskRepresents the current mask pattern of the component.
  • promptRepresents the character used for the unfilled parts of the mask.

As a result, the masked value is formatted when the user pastes or types in the input field. The value property is recomputed and uses the following configuration:

  • promptPlaceholderThe character you can use to replace the prompt character from the masked value in the value. By default, it is an empty string. The default approach facilitates the persisting of the unfilled parts of the mask in the extracted value.
  • includeLiteralsThe property that indicates whether to include literals in the value of the component. By default, includeLiterals does not include literals.

The formatting of the MaskedTextBox value triggers the valueChange event.

Example
View Source
Edit In Stackblitz  
Change Theme:

In this article

Not finding the help you need?