Creating Accessible Forms
- 1 Instructions
- 1.1 Section 5.1: The PDF Form Pipeline
- 1.2 Section 5.2: Starting in Microsoft Word
- 1.3 Section 5.3: Saving as a Tagged PDF
- 1.4 Section 5.4: Automatically Adding Form Fields
- 1.5 Section 5.5: Editing and Swapping Form Fields
- 1.5.1 Unique Field Names
- 1.5.2 Tooltips
- 1.5.3 Marking Fields as Required
- 1.5.4 Text Field
- 1.5.5 Check Boxes and Radio Buttons
- 1.5.6 Dropdown List
- 1.5.7 Buttons
- 1.5.8 Digital Signatures
- 1.5.9 Field Actions
- 1.5.10 Validations and Error Prevention
- 1.6 Section 5.6: Tab Order
- 1.7 Section 5.7: Tagging
- 1.8 Section 5.8: Tagging Other Objects
- 1.9 Section 5.9: Accessibility Checker
- 1.9.1 PAC 2021
- 1.10 Section 5.10: Testing with a Screen Reader
- 2 Related articles
Instructions
Section 5.1: The PDF Form Pipeline
The following steps are the main PDF Form Pipeline or workflow used for creating accessible PDF forms.
The PDF Form Pipeline Steps:
Create the Form in Microsoft Word
Export to Untagged PDF
Add Form Fields in Acrobat Pro
Set and Verify Form Field Properties
Check the Form Field Tab Order
Add Tags to the Document
Fine Tune the Reading Order and Tab Order
Check Accessibility
If you start with a tagged PDF document, you should delete the tags and then complete Steps 3 through 8.
Section 5.2: Starting in Microsoft Word
When you think your document is nearing completion, follow these rules to make sure your project is ready for Acrobat.
Ensure form instructions are clear.
Create visible labels for all form fields.
Ensure labels are meaningful and clear.
Place labels visually adjacent to their corresponding elements.
Include meaningful group labels where appropriate.
Indicate which form fields are required and if there are any field constraints, such as a specific format of entering the data. (This can also be done in Acrobat).
Provide help and hints where appropriate. (This can also be done in Acrobat).
Section 5.3: Saving as a Tagged PDF
When you optimize a source document for accessibility and convert it to tagged PDF, you are using a type of automated tagging. Because you've already applied accessibility features in the source document, they will carry over during conversion. This type of automatic tagging is good and will make your life easier.
To save your Word Document as a Tagged PDF,
Click on the File Tab and click Save as Adobe PDF.
In the Save As box, go to the Options Box at the bottom.
In the Acrobat PDFMaker, check Enable Accessibility and Reflow with tagged Adobe PDF and Convert Word Headings to Bookmarks.
If you want to tag the objects in the Tags Pane yourself, click on the Tags Root and click Delete Tags.
Section 5.4: Automatically Adding Form Fields
After your document has been imported into Acrobat, we need to create the form fields. Form fields are like text boxes and allow you to enter your information. There are two ways to add your forms, automatically and manually. To add your form fields automatically, you need to get the Prepare Form Tool. To activate this tool,
Go to the Tool Tab.
Go to the Forms & Signatures Section and find the Prepare Form Tool.
Click on the Prepare Form Tool’s dropdown menu and click Add Shortcut. The tool will appear in your Tools pane.
This tool will automatically add form fields to your document. One thing to keep in mind is that the tool will only create text box form fields. If you only use form fields for typing in text, that is okay, but if you need to create check boxes, or dates, or other complex form fields, you will need to make those manually. To add your form fields,
Click the Prepare Form Tool.
Select your untagged PDF. Leave the option for This Document Requires Signatures unchecked. We will add a signature line ourselves later on.
The option for Form Field Auto Detection should be left as on.
Click Start
Now your tool has added form fields to your entire PDF document. Field Names and Tooltips are also added, but you should check those to be sure they are accurate.
Section 5.5: Editing and Swapping Form Fields
Now that your form fields have been created, you need to check them all. Some fields could have been made that are not meant for their space. Others spaces may need different types of fields. A few could also have the wrong names. Be sure you check each one carefully and change them accordingly. The Prepare Form Tool gives you 10 different form types to create. These include,
Text Box
Check Box
Radio Buttons
List of Choices
Dropdown List
Action Button
Image Field
Date Field
Signature Field
Barcode Field
Many of these fields can be used in accessible ways for your project. In our example, we are going to use some of these form fields to make our application accessible. First, we are going to delete the forms that were automatically created for us that we do not need. In this case, the Date field is a text field, but we want it to be a Date Field.
To delete a form field,
Click on the form field you want deleted.
Press the Delete key.
OR
Right click on the form field you want deleted.
In the dropdown menu click Delete.
To add a new form field,
Go to the Tool Bar at the top of the screen. Click the type of form you want created. In this example we will click the calendar icon to create a Date Field.
The field is created on your cursor. Click the location where you want the field. Then scale the box to fit the location.
Now double click on the new field. The Text Field Properties box will open. Give the field a new meaningful name.
Unique Field Names
All field names need to be unique. If you do not have unique field names, Acrobat will duplicate any tool tips you made to all of the fields that share the same name. This can cause a lot of confusion if you use a similar name frequently in the document. For example, if you have a field name called Date, you cannot have another field name used in the PDF. If you do, the readers may not know what information to put down. The field many need today’s date or a different date. Keep this in mind when naming your fields.
Tooltips
When the screen reader reads the form field, the name will be read first, followed by the tooltip. Tooltips should be written like instructions telling the reader what to do for filling out the form field. When you have created a tooltip, you can hover your mouse over the form field and a small yellow box will appear with a tool tip inside. Keep in mind that tool tips should never include word for the type of field. An example could be “Check box Yes”. This is because screen readers will announce that information automatically.
To add a Tool Tip,
Double click on your form field.
In the Text Field Properties box, go to the General Tab. Type in your tooltip in the Tooltip box.
Marking Fields as Required
If you make fields required, you need two indicators for the readers to see.
Required Field Marker Indicator 1 Example:
Double Click on your form field.
In the Text Field Properties box, go to the General tab and check the Required Box.
Required Field Marker Indicator 2 Example:
You can place a notice at the top of your document. This is good for when you have a document where everything is required to be filled out.
If only certain fields are required, mark them with an asterisk or the work required in parentheses within the visible field label. Include an explanatory note in the form instructions, such as: "All fields with an asterisk are required." Then, for screen reader users, you would include the word (Required) in the tooltip.
Text Field
Text fields allow users to type in text like addresses, phone number, and names.
In our example, we will use the full name form field. When you create the form fields automatically, the name will be automatically generated. Sometimes it is accurate, but they should be checked. Tooltips are not made automatically and need to be added manually.
Check Boxes and Radio Buttons
Both check boxes and radio buttons can be made in Adobe Acrobat. However, it is not recommended to make them because there are more accessible ways to give people options. Typically, check boxes and radio buttons take several steps to access. Instead of using them, create dropdown lists with the options inside. If you want users to give you more than one answer, create a text box form field and let them type in one answer or multiple answers.
Dropdown List
A dropdown list allows a user to select a single option from a dropdown list of options.
To create a dropdown list,
Delete the form field you want replaced.
Go to the Tool Bar at the top of the screen. Select the Dropdown Menu button.
Click and drag your dropdown menu form field to create the form field in its location.
Double click the field to open the Dropdown Properties box. Include a name and tooltip.
Next, go to the Options Tab. In the Item box, type in your item and click on the Add button to add it to your item list.
Test your dropdown menu by clicking the Preview button and clicking on your dropdown menu.
Buttons
Buttons can be used to make a change on computers. You can use them to clear forms, submit forms, or open files. For our example, we will make a button to clear a form.
To make a clear form button,
Go to the Tool Bar on the top of the screen and click the Button Tool.
Click and drag to create the button on your line. In this case, the clear form line.
Go to the General Tab in the Properties box. Give the button a name and a tooltip.
Go to the Appearance Tab and set the font size to 14 and the font to Times New Roman.
Go to the Options Tab. Change Behavior to Push. Then set the Label to Clear Form.
Go to the Actions Tab and in the Select Trigger dropdown menu and choose Mouse Up. In the Select Action Dropdown menu, choose Run a JavaScript. Click Add Button. Copy and Paste the JavaScript below.
Test your new button. You should get a warning asking you to proceed. This means your script works.
Digital Signatures
A signature field allow users to sign a document with a digital signature. When you create your form fields automatically, the signature form field is made for you. When you double click on the Signature form field and go to the General tab, the name and tooltip is also made for you. Users can use their existing Digital ID or make a new one.
Field Actions
You can assign many different actions to fields by using built-in actions within Acrobat or custom JavaScript. They can be executed by mouse entry, mouse exit, mouse up, mouse down, on focus, and on blur. Examples include:
Execute a menu item
Import form data
Play a sound
Play media
Run a custom JavaScript
And more
In the Properties dialog, go to the Actions tab. There, you can either select from a list of built-in actions or enter JavaScript to perform a custom action.
Whatever actions you assign to form fields, follow these important guidelines for accessibility:
Do not include actions that rely only on mouse use. Everything must be keyboard accessible.
"On focus" actions are triggered when a field receives focus. "On blur" actions are triggered when a field loses focus. They should be avoided or used carefully.
If you assign an "on focus" action, ensure that it does not move the focus to another field, unless that field is not to be used.
Do not trap the keyboard focus in any fields. Users must be able to easily move in and out of form fields throughout the entire form using only a keyboard.
Validations and Error Prevention
When a person fills out your form, you need to be sure they have filled out the form correctly. To help the reader, we can create error messages for them to see if they place the wrong information in your form boxes.
You need to create your own Validation Script. You can do this by going to the Text Field Properties Box.
Go to the Validate Tab, check Run Custom Validation Script, then click the Edit Button.
In the JavaScript Editor, type in your JavaScript.
Section 5.6: Tab Order
Now that all of your form fields have been completed, you need to test the tab order of your PDF. A user may not be able to use the mouse to click from one form field to another. A good alternative to access the form fields is by using the Tab Key. To test your PDF, click the Preview Button and hit the Tab Key several times. What should happen is that the first form field at the top of the PDF should be highlighted first. Then by clicking the Tab Key again, the form next to or underneath the first form field will be highlighted. If a form field is skipped, that means the Tab Order is out of order. To fix the Tab Order,
Go into the Prepare Form Tool Edit Mode.
On the right side of the screen, go to the Fields Section.
The Fields Section contains all of your form fields and gives you the ability to rearrange the order of the form fields. To move the form field order, click and drag the field you want into a new position.
Go back to Preview Mode and press the Tab Key to test the new location of your form fields.
Keep tweaking the Fields Section until everything is in order.
Section 5.7: Tagging
When your PDF Tab Order is finished, it is time to tag your PDF. Tagging your form is a very long and repetitive process, but it does get easier and faster with time and practice. To tag your form field,
First, we need to create a Tags Root. Right now, we do not have one in our PDF sample. To create one, go to the Tags pane and right click on the No Tags Available text. Click Create Tags Root.
Next, go to the Options Menu and click Find.
In the Find Element box, go to the Find dropdown menu and choose Unmarked Annotations. Then check Search Document and click the Find button.
The first form field in your document should be highlighted. When you see this, click the Tag Element button.
The New Tag box will appear. In the Type dropdown menu, choose Form and click OK.
In the Tags Pane, you will see a Form Tag has been created and within it is an OBJR Tag with your form field inside it.
Go back to the Find Element box and repeat these steps until every single form field has been tagged.
Once everything has been tagged, we are going to tag our text for each form field. Start by creating a paragraph tag and placing each text inside. In this case, remember to only highlight the words and the colon. We will take care of the lines later.
Drag and drop all of the Form tags and OBJR tags into their respective Paragraph tags.
Section 5.8: Tagging Other Objects
Chapter 4 in this series has examples of how to tag most objects found in PDF documents. This section will explain what each item should be tagged as in the current situation. Feel free to apply these methods into your project if it will help your project become more accessible. But keep in mind that every project is different, so what may work in one project may not be best for another.
Object | Tag to Use |
---|---|
The Full PDF | Document Tag |
Coastal Comforts Title | Heading Tag |
Employment/Job Application | Heading 1 Tag |
(All fields are required) | Paragraph Tag |
Personal Information, Education, Previous Employment, References, Disclaimer | Heading 2 Tag |
Disclaimer Text | Paragraph Tag |
Page Numbers | Paragraph Tag |
After you have your tags created, it is time to make your screen reader ignore all of the untagged content. This includes lines, or decorative images. To do this,
Go to the Options Menu and click Find.
In the Find Element dropdown menu click on Unmarked Content, check Search Document and click Find.
A bunch of pink boxes will appear around your document. Click Tag Element. Keep clicking Tag Element until you have everything tagged.
Place all of the tagged content into its own Paragraph Tag. Be careful, you may get some important content in the tag, so be sure to move that content to its own tag for the screen reader to read.
Highlight all of the items in your Paragraph Tag and then right click. In the menu, click Change to Artifact. Now the screen reader will skip those objects when reading to the reader. Then delete your Paragraph tag.
Section 5.9: Accessibility Checker
You have now reached the last step of our process before testing with a screen reader. We need to use Adobe’s Accessibility Checker. The accessibility checker will scan our entire document, from the tags, to the font used, to the color contrast, and many other accessibility attributes. After it is done checking, the accessibility checker will give us a notification on what issues need to be fixed and what fulfills accessibility requirements. Keep in mind though, that while accessibility checkers are very good, they should not be completely depended on. Think of them as a first step for testing accessibility. If you want to see if your document is completely accessible, it is recommended to test it with a screen reader. To use Acrobat’s Accessibility Checker,
Open the Accessibility Tool and click the Accessibility Check button.
In the Accessibility Checker Options box, you will see a list of 32 different attributes the accessibility checker will analyze. Click the Start Checking button to make it look for every issue.
On the left side of the screen, you will receive several dropdown menus of issues that need to be fixed. When you open the menus and select the issues, you can find instructions on how to fix the problems.
When you have all of your issues fixed, start testing your document with a screen reader.
PAC 2021
As discussed in previous sections of this series, PDF Accessibility Checker 2021 or PAC 2021 is an accessibility checker made for checking the accessibility of PDFs. This would be a good resource to use to compare results to the accessibility checker in Adobe Acrobat. To use PAC 2021,
Click on the upload button and select your PDF.
PAC 2021 will analyze your document and see if it passes WCAG 2.1 standards as well as PDF/UA Standards. For these examples we only need to worry about WCAG 2.1 standards and any new WCAG standards as they are released.
Section 5.10: Testing with a Screen Reader
Use NVDA or another screen reader to test your PDF. Everything in your PDF should be read by the screen reader in order. If anything is skipped, be sure to fix the reading order or tab order or any additional issues you may run into. Once you are done, the PDF should be fully accessible, and you can share it with your student, or other faculty that need it.