18. Working with Data Types and Data Display Formats : String Input Templates : String Template Creation : Predefined Characters for Custom Character Sets
 
Share this page                  
Predefined Characters for Custom Character Sets
You are also given a set of predefined special characters that you can use in the definition of a custom character set. These characters represent a pre‑defined set of characters and can appear only in a custom character set definition. You cannot place them directly in a template definition. These special characters are useful because you can force the case or apply a default to any of the characters represented by these built‑in special characters. (The pre‑defined special characters described in The Special Characters do not allow you to apply forced case or a default to any of the characters that they represent.)
The predefined special characters that you can use in a custom character set definition are as follows:
#
The pound sign represents any digit.
@
The at sign represents any alphabetic character.
*
The asterisk represents any printable character.
+
The plus sign represents any printable character (only 7 bits).
&
The ampersand represents any character that can be the first character in a name.
%
The percent sign represents the second and subsequent characters in a name.
:
The colon represents any hexadecimal digit.
Use these characters when you want to force the case of an entry or provide a default for the entry. For example, to specify a four‑letter entry, use a template that looks like this:
aaaa
However, assume that you want the first position to be an uppercase letter. Because you cannot force case on the special character a, you must use the special character @ instead:
[@/u]aaa
If you want to include any of these special characters as literals in the template, use the escape character with the character. For example, you want the user to enter a two‑figure percentage value. A template looks like this:
nn\%