TextBox.Mask

Usage:

Read and write.

Description:

Type: String.
Contains the character string of mask used to enter text in the box interactively. Mask string can include the following special characters:
  • ! - any character entered is converted to uppercase;
  • 9 - allows to enter any numeric character;
  • # - allows to enter any numeric character, - (minus sign), + (plus sign) or space;
  • N - allows to enter any alphanumeric characters;
  • U - allows to enter any alphanumeric characters, which are automatically converted to uppercase;
  • X - allows to enter any single character;
  • ^ - this character can not be entered by user interactively and is set only by means of language;
  • h - allows to enter hexadecimal digits;
  • @ - allows to enter any uppercase alphanumeric character or a space.

When a value from the mask text box is put into text attribute associated with the latter, it is converted in the following way: in all places where there is a "@" character in the mask and a space in the string, the space is deleted. If a mask composed of special characters contains only "@" characters, then all text characters that correspond to non-special characters of mask and are situated after the last non-empty @-block are removed. For example, if the mask is "@@.@@.@@.", the text "41. 2. ." is converted to "41.2".
To use in a mask one of special symbols, it is necessary to use before it a symbol "\".
The instruction of several masks in one parameter is supposed. Masks are divided by a symbol ";". That mask to which the entered text approaches will be used in this case.

Availability:

Thick client.

Note:

This attribute applies only to String values.
If the string put in the text box corresponds to an empty mask, the value is set to an empty string.
If an attribute uses the string of fixed length, the space will be added to a value to the specified length.

    

1C:Enterprise Developer's Community