Operation Manual

Parameter Fields and Prompts
Advanced parameter features
23
Crystal Reports User’s Guide 467
Defining entry type and format using the Edit Mask
1. On the View menu, click Field Explorer.
2. Select Parameter Fields and click New.
The Create New Parameter dialog box appears.
3. Enter the Name and value Type.
4. For a string parameter field, you can choose to enter an edit mask in the
Edit mask field, rather than specifying a range.
An edit mask can be any of a set of masking characters used to restrict
the values you can enter as parameter values (the edit mask also limits
the values you can enter as default prompting values).
You can enter any of the following masking characters, or any
combination of them:
A” (allows an alphanumeric character and requires the entry of a
character in the parameter value).
a” (allows an alphanumeric character and does not require the entry
of a character in the parameter value).
0” (allows a digit [0 to 9] and requires the entry of a character in the
parameter value).
9” (allows a digit or a space, and does not require the entry of a
character in the parameter value).
#” (allows a digit, space, or plus/minus sign, and does not require
the entry of a character in the parameter value).
L” (allows a letter [A to Z], and requires the entry of a character in
the parameter value).
?” (allows a letter, and does not require the entry of a character in
the parameter value).
&” (allows any character or space, and requires the entry of a
character in the parameter value).
C” (allows any character or space, and does not require the entry of
a character in the parameter value).
. , : ; - /” (separator characters). Inserting separator characters
into an edit mask is something like hard coding the formatting for the
parameter field. When the field is placed on the report, the separator
character will appear in the field object frame, like this: LLLL/0000.
This example depicts an edit mask that requires four letters followed
by four numbers.
<“ (causes subsequent characters to be converted to lowercase).