Software

Add data validation to an Access form

All is not lost if you didn't set data validation for a field during table design. See how you can add data validation to an Access form in four simple steps.

Help users increase productivity by automatically signing up for TechRepublic's free Microsoft Office Suite newsletter, featuring Word, Excel, and Access tips, delivered each Wednesday.

Even if you didn't set data validation for a field during table design in Microsoft Access, you can still validate data through the form's Validation Rule property.

For instance, suppose you want to ensure that the right data is entered in the Gender field. With the form in design view, follow these steps to make sure that data related to gender goes into the Gender field:

  1. Right-click the Gender field and select Properties.
  2. Click the Data tab.
  3. Enter the following code for the Validation Rule property:
  4. M Or F
  5. Enter the following text in the Validation text box:
Type M for Male or F for Female

If the user tries to type anything other than an M or F, Access will display the message "Type M for Male or F for Female" in the Validation text box.

0 comments

Editor's Picks