Validating field length is a fundamental type of validation rule. This is useful for requiring a field entry (length > 0), for limiting the lengh of a field (length < 10) or for matching a specific number of characters like a credit card acccount number (length = 16).
NOTE: The features described are for use with the Classic-style Form Builder. If you are using the SharePoint Modern experience, our recommendation is to use the newer Form designer tool – validation is one of the functions controlled as a part of that, rather than as a stand-alone.
- Let's create a validation rule that must have an entry (more than 0 characters) and also must not be over 20 characters in length.
- Begin by creating a rule which requires length > 0.
- Click the Add button. Then Save out of the form.
Validate Empty Columns
You must enable validation of empty columns. If this setting is disabled, blank fields will be ignored by validation rules.
- Create a second rule to limit the length:
- After creating validation rules always check your work.
- Validation rules can sometimes take some trial and error before arriving at the intended settings.
Field length validation is a fundamental building block in form validation. This can be used in conunction with other types of validation to carefully control user input and ensure that you receive valid data.
10/1/2019 3:43 PM