Microsoft Office Tutorials and References
In Depth Information
To view and change the input mask for the Phone field:
1. Save the table, and then switch to Datasheet view. The Phone field values now
have the format specified by the input mask.
Sarah decides that she would prefer to omit the parentheses around the area
codes and use only hyphens as separators in the displayed Phone field values, so
you’ll change the input mask in Design view.
2. Switch to Design view.
The input mask changed from !(999) 000-0000;;_ to !\(999”) “000\-0000;;_. The
backslash character (\) causes the character that follows it to appear as a literal
display character. Characters enclosed in quotation marks also appear as literal
display characters. (See Figure 5-37.)
3. Change the input mask to 999\-000\-0000;;_ in the Input Mask text box for the
Phone field, and then press the Tab key.
Because you’ve modified a field property, the Property Update Options button
appears to the left of the Input Mask property.
4. Click the Property Update Options button, and then click Update Input Mask
everywhere Phone is used . The Update Properties dialog box opens. See Figure 5-38.
If you omit the backslashes
preceding the hyphens,
Access will automatically
insert them when you
press the Tab key. How-
ever, Access doesn’t add
for other literal display
characters, such as periods
and slashes, so it’s best to
always include the
Update Properties dialog box
o bjects dependent
on the Phone field
Because the frmCustomer and frmCustomerContracts forms display Phone field
values from the tblCustomer table, Access will automatically change the Phone
field’s Input Mask property in these objects to your new input mask. This capability
to update field properties in objects automatically when you modify a table field
property is called property propagation . Although the Update Properties dialog
box displays no queries, property propagation also does occur with queries
automatically. Property propagation is limited to field properties such as the Deci-
mal Places, Description, Format, and Input Mask properties.
5. Click the Yes button, save the table, and then switch to Datasheet view. The Phone
field values now have the format Sarah requested. See Figure 5-39.
After changing the Phone field input mask
Phone field with input mask