ACC2000: Error Message Using AutoKeys Macro (209197)



The information in this article applies to:

  • Microsoft Access 2000

This article was previously published under Q209197
Moderate: Requires basic macro, coding, and interoperability skills.

SUMMARY

If you use an invalid key combination in an AutoKeys macro in Microsoft Access, you may receive the following error message:
The key or key combination <. . .> in AutoKeys has invalid syntax or is not allowed.

Use the SendKeys syntax to specify the key or key combinations.
For the allowed key or key combinations, click Help.

MORE INFORMATION

When you open a database, Microsoft Access looks for a macro with the name AutoKeys. You receive an error if that macro contains a key combination that is not in the following list:
SendKeys Syntax ExampleKey Combination
^A or ^4CTRL+any letter or number
{F1}Any function key
^{F1}CTRL+any function key
+{F1}SHIFT+any function key
{INSERT}INS key
^{INSERT}CTRL+INS key
+{INSERT}SHIFT+INS key
{DELETE} or {DEL}DEL key
^{DELETE} or ^{DEL}CTRL+DEL key
SHIFT+DEL keySHIFT+DEL key

Steps to Reproduce Behavior

  1. Create a new macro.
  2. Type +Z in the Macro Name column.
  3. Type Beep in the Action column.
  4. Save the macro as AutoKeys. Note that you receive the following error message:
    The key or key combination +Z in AutoKeys has invalid syntax or is not
    allowed.

    Use the SendKeys syntax to specify the key or key combinations.
    For the allowed key or key combinations, click Help.

REFERENCES

For more information about AutoKeys, click Microsoft Access Help on the Help menu, type AutoKeys in the Office Assistant or the Answer Wizard, and then click Search to view the topics returned.

Modification Type:MajorLast Reviewed:11/29/2000
Keywords:kberrmsg kbinfo KB209197