Skip to main content
W
Microsoft WordLow Priority1 accessibility check

Security and Macros in Word Documents

Documents with macros or active content may have accessibility implications.

Security and Macros in Word Documents

Documents containing macros or active content can have accessibility implications. While macros themselves aren't inherently inaccessible, they require special consideration to ensure they work with assistive technology.

What This Means

Macros are automated scripts that perform actions in Word documents. If your document contains macros, you should ensure any functionality they provide is accessible to users who rely on keyboards or screen readers.

Why It Matters

  • Security warnings can confuse users when opening documents
  • Macro-driven features may not work with screen readers
  • Keyboard accessibility must be maintained for all macro functions
  • Alternative workflows should exist for users who disable macros

Common Violations

DOCX-10-001: Document Contains Macros or Active Content {#DOCX-10-001}

What's Wrong: The document contains macros or other active content that may present accessibility challenges.

Impact: Minor - This is informational; macros aren't inherently inaccessible but require attention.

How to Identify:

  1. When you open the document, you may see a security warning
  2. Check File > Options > Trust Center for macro settings
  3. Go to View > Macros to see if any macros exist

Common Macro Uses:

  • Form automation
  • Custom navigation buttons
  • Document protection workflows
  • Automated formatting

Accessibility Considerations for Macros

Keyboard Accessibility

Any functionality provided by macros should be:

  • Accessible via keyboard shortcuts
  • Available through standard menu commands
  • Operable without requiring mouse clicks

Assigning Keyboard Shortcuts to Macros:

  1. Go to File > Options > Customize Ribbon
  2. Click Customize next to Keyboard shortcuts
  3. In Categories, select Macros
  4. Select your macro
  5. Assign a keyboard shortcut
  6. Click Assign

Screen Reader Compatibility

Macro-driven features should:

  • Provide feedback that screen readers can announce
  • Not interfere with standard screen reader navigation
  • Include status messages using accessible methods

Error Handling

Macros should:

  • Display error messages in accessible dialog boxes
  • Not assume users can see visual indicators
  • Provide clear instructions for resolving issues

Alternatives to Macros

Consider whether macros are necessary:

For Form Fields:

  • Use Word's built-in content controls instead
  • These are more accessible than macro-driven forms

For Navigation:

  • Use headings and the Navigation Pane
  • Use bookmarks and hyperlinks

For Formatting:

  • Use styles and templates
  • Use Quick Parts for reusable content

For Protection:

  • Use Word's built-in protection features
  • Use Restrict Editing instead of macro-based locks

Best Practices for Accessible Macros

Do:

  • Assign keyboard shortcuts to all macro functions
  • Test macros with screen readers
  • Provide alternative ways to accomplish tasks
  • Document macro functionality and shortcuts
  • Use accessible message boxes for user feedback

Don't:

  • Require mouse interaction for macro features
  • Rely solely on visual feedback
  • Block screen reader navigation
  • Assume all users can enable macros

Macro Security Settings

Users may disable macros for security:

  1. Disable all macros without notification - Macros won't run at all
  2. Disable all macros with notification - Users can choose to enable
  3. Disable all macros except digitally signed - Only trusted macros run
  4. Enable all macros - All macros run (not recommended)

For Accessible Documents:

  • Ensure core document content is accessible without macros
  • Macro features should enhance, not replace, standard functionality

Creating Accessible Macro Forms

If using macros for forms:

  1. Label all form fields - Use descriptive labels next to fields
  2. Provide instructions - Explain how to complete the form
  3. Use Tab order - Ensure logical keyboard navigation
  4. Include error messages - Accessible feedback for validation
  5. Consider built-in alternatives - Content controls may be more accessible

Document Security Without Macros

Word provides built-in security features:

Restrict Editing

  1. Go to Review > Restrict Editing
  2. Choose formatting or editing restrictions
  3. Set a password if needed

Mark as Final

  1. Go to File > Info > Protect Document
  2. Select Mark as Final
  3. Document becomes read-only (but can be edited if needed)

Password Protection

  1. Go to File > Info > Protect Document
  2. Select Encrypt with Password
  3. Note: This doesn't affect accessibility, just access

Additional Resources

Scan Your Word Documents for Accessibility Issues

Beacon automatically detects Word accessibility violations and shows you exactly how to fix them.

Start Free Scan