To ensure that data is collected in a certain way in a text field, you can use the Enforce pattern option.
Set Enforce pattern to Yes. You can use a "?" to allow your users to enter any value. Use a "#" to force the user to enter a number. Other characters will be fixed text in the text field value.
For example, you can enforce a pattern for users to enter a phone number.
On form start the user is forced to enter values according to the set pattern.
Below are some other examples of text field patterns you could use:
NPA-NXX phone number
(###) ###-####
ISO 8601 date
####-##-##
US zip code
#####
VISA
#### #### #### ####
DLS (no quarter or LSD)
##-###-## W#
DLS (LSD)
##-##-###-## W#
DLS (quarter)
?? ##-###-## W#
NTS
NTS ##-?-## BLK ? UNIT ##
UWI (DLS)
100/##-##-###-##-W#/##
UWI (NTS)
200/?-###-?/###-?-##/##
UWI (API)
##-###-#####-##-##
See also: