Share this page

# Defining Input Masks

The input mask option is used to prompt users for data input using a mask pattern. If the user attempts to enter a character that conflicts with the input mask, an error occurs. For example, to prompt the user to enter a phone number, you can define the following input mask:

`!\(000\)000-0000`

This input mask limits the user to numeric characters only. It is displayed in an edit box as follows:

`(___) ___ - ____`

Note: You can define input masks for string type fields only.

To define an input mask:

1. In the Settings tab, select Masked. For details, see Customizing Project Entities.

2. Under Masked Edit Attributes, click the Define button. The Input Mask Editor dialog box opens.

3. In the Input Mask box, type an input mask or select a predefined mask.

   You can use the following characters when defining input masks:

   Mask Character | Description
   --- | ---
   ! | A space for a leading or trailing blank.
   # | A digit.
   . | A decimal.
   : | A time separator.
   / | A date separator.
   \ | Treats the next character in the mask string as a literal. For example, you can include the (, ), #, &, A, and ? characters in the mask.
   > | Converts all the characters that follow to uppercase.
   < | Converts all the characters that follow to lowercase.
   A | An alphanumeric character (entry required). For example: a – z, A – Z, or 0 – 9.
   a | An alphanumeric character (entry optional). For example: a – z, A – Z, or 0 – 9.
   C | A character (entry required). Valid values are ANSI characters in the following ranges: 32-126 and 128-255.
   c | A character (entry optional). Valid values are ANSI characters in the following ranges: 32-126 and 128-255.
   L | An alphabetic character or space (entry required). For example: a – z or A – Z.
   l | An alphabetic character or space (entry optional). For example: a – z or A – Z.
   0 | A digit (entry required). For example: 0 – 9.
   9 | A digit (entry optional). For example: 0 – 9.
   _ | Inserts spaces. When the user types characters in the field box, the cursor skips the _ character.

4. In the Test Input box, you can test the input mask.

5. Click OK to close the Input Mask Editor dialog box.

6. Click Save to save your changes to the Project Entities page.

Back to top

https://admhelp.microfocus.com ALM 8942
Tips to improve your search results... ALM Help Center ALM Help Center ALM Help 15.5-15.5.1 All View Local Help Center View Online Help Center back Go back in browser history forward Go forward in browser history Remove search highlights next topic Go to next topic previous topic Go to previous topic Print the current topic Version: